Gallery Application Version
Specifies information about the gallery Application Version that you want to create or update. API Version: 2020-09-30.
Example Usage
Create or update a simple gallery Application Version.
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var galleryApplicationVersion = new AzureNative.Compute.GalleryApplicationVersion("galleryApplicationVersion", new()
{
GalleryApplicationName = "myGalleryApplicationName",
GalleryApplicationVersionName = "1.0.0",
GalleryName = "myGalleryName",
Location = "West US",
PublishingProfile = new AzureNative.Compute.Inputs.GalleryApplicationVersionPublishingProfileArgs
{
EndOfLifeDate = "2019-07-01T07:00:00Z",
ManageActions = new AzureNative.Compute.Inputs.UserArtifactManageArgs
{
Install = "powershell -command \"Expand-Archive -Path package.zip -DestinationPath C:\\package\"",
Remove = "del C:\\package ",
},
ReplicaCount = 1,
Source = new AzureNative.Compute.Inputs.UserArtifactSourceArgs
{
MediaLink = "https://mystorageaccount.blob.core.windows.net/mycontainer/package.zip?{sasKey}",
},
StorageAccountType = "Standard_LRS",
TargetRegions = new[]
{
new AzureNative.Compute.Inputs.TargetRegionArgs
{
Name = "West US",
RegionalReplicaCount = 1,
StorageAccountType = "Standard_LRS",
},
},
},
ResourceGroupName = "myResourceGroup",
});
});
Content copied to clipboard
package main
import (
compute "github.com/pulumi/pulumi-azure-native-sdk/compute"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := compute.NewGalleryApplicationVersion(ctx, "galleryApplicationVersion", &compute.GalleryApplicationVersionArgs{
GalleryApplicationName: pulumi.String("myGalleryApplicationName"),
GalleryApplicationVersionName: pulumi.String("1.0.0"),
GalleryName: pulumi.String("myGalleryName"),
Location: pulumi.String("West US"),
PublishingProfile: compute.GalleryApplicationVersionPublishingProfileResponse{
EndOfLifeDate: pulumi.String("2019-07-01T07:00:00Z"),
ManageActions: &compute.UserArtifactManageArgs{
Install: pulumi.String("powershell -command \"Expand-Archive -Path package.zip -DestinationPath C:\\package\""),
Remove: pulumi.String("del C:\\package "),
},
ReplicaCount: pulumi.Int(1),
Source: &compute.UserArtifactSourceArgs{
MediaLink: pulumi.String("https://mystorageaccount.blob.core.windows.net/mycontainer/package.zip?{sasKey}"),
},
StorageAccountType: pulumi.String("Standard_LRS"),
TargetRegions: compute.TargetRegionArray{
&compute.TargetRegionArgs{
Name: pulumi.String("West US"),
RegionalReplicaCount: pulumi.Int(1),
StorageAccountType: pulumi.String("Standard_LRS"),
},
},
},
ResourceGroupName: pulumi.String("myResourceGroup"),
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.compute.GalleryApplicationVersion;
import com.pulumi.azurenative.compute.GalleryApplicationVersionArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var galleryApplicationVersion = new GalleryApplicationVersion("galleryApplicationVersion", GalleryApplicationVersionArgs.builder()
.galleryApplicationName("myGalleryApplicationName")
.galleryApplicationVersionName("1.0.0")
.galleryName("myGalleryName")
.location("West US")
.publishingProfile(Map.ofEntries(
Map.entry("endOfLifeDate", "2019-07-01T07:00:00Z"),
Map.entry("manageActions", Map.ofEntries(
Map.entry("install", "powershell -command \"Expand-Archive -Path package.zip -DestinationPath C:\\package\""),
Map.entry("remove", "del C:\\package ")
)),
Map.entry("replicaCount", 1),
Map.entry("source", Map.of("mediaLink", "https://mystorageaccount.blob.core.windows.net/mycontainer/package.zip?{sasKey}")),
Map.entry("storageAccountType", "Standard_LRS"),
Map.entry("targetRegions", Map.ofEntries(
Map.entry("name", "West US"),
Map.entry("regionalReplicaCount", 1),
Map.entry("storageAccountType", "Standard_LRS")
))
))
.resourceGroupName("myResourceGroup")
.build());
}
}
Content copied to clipboard
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:compute:GalleryApplicationVersion 1.0.0 /subscriptions/01523d7c-60da-455e-adef-521b547922c4/resourceGroups/galleryPsTestRg98/providers/Microsoft.Compute/galleries/galleryPsTestGallery6165/applications/galleryPsTestGalleryApplication7825/versions/1.0.0
Content copied to clipboard
Properties
Link copied to clipboard
The provisioning state, which only appears in the response.
Link copied to clipboard
The publishing profile of a gallery image version.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
This is the replication status of the gallery image version.