Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azurenative.devtestlab.kotlin
import com.pulumi.azurenative.devtestlab.CustomImageArgs.builder
import com.pulumi.azurenative.devtestlab.kotlin.inputs.CustomImagePropertiesCustomArgs
import com.pulumi.azurenative.devtestlab.kotlin.inputs.CustomImagePropertiesCustomArgsBuilder
import com.pulumi.azurenative.devtestlab.kotlin.inputs.CustomImagePropertiesFromPlanArgs
import com.pulumi.azurenative.devtestlab.kotlin.inputs.CustomImagePropertiesFromPlanArgsBuilder
import com.pulumi.azurenative.devtestlab.kotlin.inputs.CustomImagePropertiesFromVmArgs
import com.pulumi.azurenative.devtestlab.kotlin.inputs.CustomImagePropertiesFromVmArgsBuilder
import com.pulumi.azurenative.devtestlab.kotlin.inputs.DataDiskStorageTypeInfoArgs
import com.pulumi.azurenative.devtestlab.kotlin.inputs.DataDiskStorageTypeInfoArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName
/**
* A custom image.
* Azure REST API version: 2018-09-15. Prior API version in Azure Native 1.x: 2018-09-15.
* Other available API versions: 2016-05-15.
* ## Example Usage
* ### CustomImages_CreateOrUpdate
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using AzureNative = Pulumi.AzureNative;
* return await Deployment.RunAsync(() =>
* {
* var customImage = new AzureNative.DevTestLab.CustomImage("customImage", new()
* {
* Description = "My Custom Image",
* LabName = "{labName}",
* Name = "{customImageName}",
* ResourceGroupName = "resourceGroupName",
* Tags =
* {
* { "tagName1", "tagValue1" },
* },
* Vm = new AzureNative.DevTestLab.Inputs.CustomImagePropertiesFromVmArgs
* {
* LinuxOsInfo = new AzureNative.DevTestLab.Inputs.LinuxOsInfoArgs
* {
* LinuxOsState = AzureNative.DevTestLab.LinuxOsState.NonDeprovisioned,
* },
* SourceVmId = "/subscriptions/{subscriptionId}/resourcegroups/resourceGroupName/providers/microsoft.devtestlab/labs/{labName}/virtualmachines/{vmName}",
* },
* });
* });
* ```
* ```go
* package main
* import (
* devtestlab "github.com/pulumi/pulumi-azure-native-sdk/devtestlab/v2"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := devtestlab.NewCustomImage(ctx, "customImage", &devtestlab.CustomImageArgs{
* Description: pulumi.String("My Custom Image"),
* LabName: pulumi.String("{labName}"),
* Name: pulumi.String("{customImageName}"),
* ResourceGroupName: pulumi.String("resourceGroupName"),
* Tags: pulumi.StringMap{
* "tagName1": pulumi.String("tagValue1"),
* },
* Vm: &devtestlab.CustomImagePropertiesFromVmArgs{
* LinuxOsInfo: &devtestlab.LinuxOsInfoArgs{
* LinuxOsState: pulumi.String(devtestlab.LinuxOsStateNonDeprovisioned),
* },
* SourceVmId: pulumi.String("/subscriptions/{subscriptionId}/resourcegroups/resourceGroupName/providers/microsoft.devtestlab/labs/{labName}/virtualmachines/{vmName}"),
* },
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azurenative.devtestlab.CustomImage;
* import com.pulumi.azurenative.devtestlab.CustomImageArgs;
* import com.pulumi.azurenative.devtestlab.inputs.CustomImagePropertiesFromVmArgs;
* import com.pulumi.azurenative.devtestlab.inputs.LinuxOsInfoArgs;
* 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 customImage = new CustomImage("customImage", CustomImageArgs.builder()
* .description("My Custom Image")
* .labName("{labName}")
* .name("{customImageName}")
* .resourceGroupName("resourceGroupName")
* .tags(Map.of("tagName1", "tagValue1"))
* .vm(CustomImagePropertiesFromVmArgs.builder()
* .linuxOsInfo(LinuxOsInfoArgs.builder()
* .linuxOsState("NonDeprovisioned")
* .build())
* .sourceVmId("/subscriptions/{subscriptionId}/resourcegroups/resourceGroupName/providers/microsoft.devtestlab/labs/{labName}/virtualmachines/{vmName}")
* .build())
* .build());
* }
* }
* ```
* ## Import
* An existing resource can be imported using its type token, name, and identifier, e.g.
* ```sh
* $ pulumi import azure-native:devtestlab:CustomImage {customImageName} /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DevTestLab/labs/{labName}/customimages/{name}
* ```
* @property author The author of the custom image.
* @property customImagePlan Storage information about the plan related to this custom image
* @property dataDiskStorageInfo Storage information about the data disks present in the custom image
* @property description The description of the custom image.
* @property isPlanAuthorized Whether or not the custom images underlying offer/plan has been enabled for programmatic deployment
* @property labName The name of the lab.
* @property location The location of the resource.
* @property managedImageId The Managed Image Id backing the custom image.
* @property managedSnapshotId The Managed Snapshot Id backing the custom image.
* @property name The name of the custom image.
* @property resourceGroupName The name of the resource group.
* @property tags The tags of the resource.
* @property vhd The VHD from which the image is to be created.
* @property vm The virtual machine from which the image is to be created.
*/
public data class CustomImageArgs(
public val author: Output? = null,
public val customImagePlan: Output? = null,
public val dataDiskStorageInfo: Output>? = null,
public val description: Output? = null,
public val isPlanAuthorized: Output? = null,
public val labName: Output? = null,
public val location: Output? = null,
public val managedImageId: Output? = null,
public val managedSnapshotId: Output? = null,
public val name: Output? = null,
public val resourceGroupName: Output? = null,
public val tags: Output