All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azure.compute.kotlin.GalleryApplicationArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 6.21.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.compute.kotlin

import com.pulumi.azure.compute.GalleryApplicationArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 * Manages a Gallery Application.
 * ## Example Usage
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 * const example = new azure.core.ResourceGroup("example", {
 *     name: "example-rg",
 *     location: "West Europe",
 * });
 * const exampleSharedImageGallery = new azure.compute.SharedImageGallery("example", {
 *     name: "examplegallery",
 *     resourceGroupName: example.name,
 *     location: example.location,
 * });
 * const exampleGalleryApplication = new azure.compute.GalleryApplication("example", {
 *     name: "example-app",
 *     galleryId: exampleSharedImageGallery.id,
 *     location: example.location,
 *     supportedOsType: "Linux",
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_azure as azure
 * example = azure.core.ResourceGroup("example",
 *     name="example-rg",
 *     location="West Europe")
 * example_shared_image_gallery = azure.compute.SharedImageGallery("example",
 *     name="examplegallery",
 *     resource_group_name=example.name,
 *     location=example.location)
 * example_gallery_application = azure.compute.GalleryApplication("example",
 *     name="example-app",
 *     gallery_id=example_shared_image_gallery.id,
 *     location=example.location,
 *     supported_os_type="Linux")
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Azure = Pulumi.Azure;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Azure.Core.ResourceGroup("example", new()
 *     {
 *         Name = "example-rg",
 *         Location = "West Europe",
 *     });
 *     var exampleSharedImageGallery = new Azure.Compute.SharedImageGallery("example", new()
 *     {
 *         Name = "examplegallery",
 *         ResourceGroupName = example.Name,
 *         Location = example.Location,
 *     });
 *     var exampleGalleryApplication = new Azure.Compute.GalleryApplication("example", new()
 *     {
 *         Name = "example-app",
 *         GalleryId = exampleSharedImageGallery.Id,
 *         Location = example.Location,
 *         SupportedOsType = "Linux",
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/compute"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
 * 			Name:     pulumi.String("example-rg"),
 * 			Location: pulumi.String("West Europe"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		exampleSharedImageGallery, err := compute.NewSharedImageGallery(ctx, "example", &compute.SharedImageGalleryArgs{
 * 			Name:              pulumi.String("examplegallery"),
 * 			ResourceGroupName: example.Name,
 * 			Location:          example.Location,
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		_, err = compute.NewGalleryApplication(ctx, "example", &compute.GalleryApplicationArgs{
 * 			Name:            pulumi.String("example-app"),
 * 			GalleryId:       exampleSharedImageGallery.ID(),
 * 			Location:        example.Location,
 * 			SupportedOsType: pulumi.String("Linux"),
 * 		})
 * 		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.azure.core.ResourceGroup;
 * import com.pulumi.azure.core.ResourceGroupArgs;
 * import com.pulumi.azure.compute.SharedImageGallery;
 * import com.pulumi.azure.compute.SharedImageGalleryArgs;
 * import com.pulumi.azure.compute.GalleryApplication;
 * import com.pulumi.azure.compute.GalleryApplicationArgs;
 * 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 example = new ResourceGroup("example", ResourceGroupArgs.builder()
 *             .name("example-rg")
 *             .location("West Europe")
 *             .build());
 *         var exampleSharedImageGallery = new SharedImageGallery("exampleSharedImageGallery", SharedImageGalleryArgs.builder()
 *             .name("examplegallery")
 *             .resourceGroupName(example.name())
 *             .location(example.location())
 *             .build());
 *         var exampleGalleryApplication = new GalleryApplication("exampleGalleryApplication", GalleryApplicationArgs.builder()
 *             .name("example-app")
 *             .galleryId(exampleSharedImageGallery.id())
 *             .location(example.location())
 *             .supportedOsType("Linux")
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: azure:core:ResourceGroup
 *     properties:
 *       name: example-rg
 *       location: West Europe
 *   exampleSharedImageGallery:
 *     type: azure:compute:SharedImageGallery
 *     name: example
 *     properties:
 *       name: examplegallery
 *       resourceGroupName: ${example.name}
 *       location: ${example.location}
 *   exampleGalleryApplication:
 *     type: azure:compute:GalleryApplication
 *     name: example
 *     properties:
 *       name: example-app
 *       galleryId: ${exampleSharedImageGallery.id}
 *       location: ${example.location}
 *       supportedOsType: Linux
 * ```
 * 
 * ## Import
 * Gallery Applications can be imported using the `resource id`, e.g.
 * ```sh
 * $ pulumi import azure:compute/galleryApplication:GalleryApplication example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.Compute/galleries/gallery1/applications/galleryApplication1
 * ```
 * @property description A description of the Gallery Application.
 * @property endOfLifeDate The end of life date in RFC3339 format of the Gallery Application.
 * @property eula The End User Licence Agreement of the Gallery Application.
 * @property galleryId The ID of the Shared Image Gallery. Changing this forces a new resource to be created.
 * @property location The Azure Region where the Gallery Application exists. Changing this forces a new resource to be created.
 * @property name The name of the Gallery Application. Changing this forces a new resource to be created.
 * @property privacyStatementUri The URI containing the Privacy Statement associated with the Gallery Application.
 * @property releaseNoteUri The URI containing the Release Notes associated with the Gallery Application.
 * @property supportedOsType The type of the Operating System supported for the Gallery Application. Possible values are `Linux` and `Windows`. Changing this forces a new resource to be created.
 * @property tags A mapping of tags to assign to the Gallery Application.
 */
public data class GalleryApplicationArgs(
    public val description: Output? = null,
    public val endOfLifeDate: Output? = null,
    public val eula: Output? = null,
    public val galleryId: Output? = null,
    public val location: Output? = null,
    public val name: Output? = null,
    public val privacyStatementUri: Output? = null,
    public val releaseNoteUri: Output? = null,
    public val supportedOsType: Output? = null,
    public val tags: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.compute.GalleryApplicationArgs =
        com.pulumi.azure.compute.GalleryApplicationArgs.builder()
            .description(description?.applyValue({ args0 -> args0 }))
            .endOfLifeDate(endOfLifeDate?.applyValue({ args0 -> args0 }))
            .eula(eula?.applyValue({ args0 -> args0 }))
            .galleryId(galleryId?.applyValue({ args0 -> args0 }))
            .location(location?.applyValue({ args0 -> args0 }))
            .name(name?.applyValue({ args0 -> args0 }))
            .privacyStatementUri(privacyStatementUri?.applyValue({ args0 -> args0 }))
            .releaseNoteUri(releaseNoteUri?.applyValue({ args0 -> args0 }))
            .supportedOsType(supportedOsType?.applyValue({ args0 -> args0 }))
            .tags(
                tags?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            ).build()
}

/**
 * Builder for [GalleryApplicationArgs].
 */
@PulumiTagMarker
public class GalleryApplicationArgsBuilder internal constructor() {
    private var description: Output? = null

    private var endOfLifeDate: Output? = null

    private var eula: Output? = null

    private var galleryId: Output? = null

    private var location: Output? = null

    private var name: Output? = null

    private var privacyStatementUri: Output? = null

    private var releaseNoteUri: Output? = null

    private var supportedOsType: Output? = null

    private var tags: Output>? = null

    /**
     * @param value A description of the Gallery Application.
     */
    @JvmName("ehvxfvecwgqqgxis")
    public suspend fun description(`value`: Output) {
        this.description = value
    }

    /**
     * @param value The end of life date in RFC3339 format of the Gallery Application.
     */
    @JvmName("vihcttwgbebrlepu")
    public suspend fun endOfLifeDate(`value`: Output) {
        this.endOfLifeDate = value
    }

    /**
     * @param value The End User Licence Agreement of the Gallery Application.
     */
    @JvmName("hheosuesanxcljgp")
    public suspend fun eula(`value`: Output) {
        this.eula = value
    }

    /**
     * @param value The ID of the Shared Image Gallery. Changing this forces a new resource to be created.
     */
    @JvmName("fruacedrjceotmvw")
    public suspend fun galleryId(`value`: Output) {
        this.galleryId = value
    }

    /**
     * @param value The Azure Region where the Gallery Application exists. Changing this forces a new resource to be created.
     */
    @JvmName("kxwxivoignuilqyk")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value The name of the Gallery Application. Changing this forces a new resource to be created.
     */
    @JvmName("uqsclrwpynxdsacd")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The URI containing the Privacy Statement associated with the Gallery Application.
     */
    @JvmName("jljpnvskwpyfqbfw")
    public suspend fun privacyStatementUri(`value`: Output) {
        this.privacyStatementUri = value
    }

    /**
     * @param value The URI containing the Release Notes associated with the Gallery Application.
     */
    @JvmName("xjoighyviogdsfrw")
    public suspend fun releaseNoteUri(`value`: Output) {
        this.releaseNoteUri = value
    }

    /**
     * @param value The type of the Operating System supported for the Gallery Application. Possible values are `Linux` and `Windows`. Changing this forces a new resource to be created.
     */
    @JvmName("fmlpqasqvgwesllu")
    public suspend fun supportedOsType(`value`: Output) {
        this.supportedOsType = value
    }

    /**
     * @param value A mapping of tags to assign to the Gallery Application.
     */
    @JvmName("hplheetcrjqblveo")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value A description of the Gallery Application.
     */
    @JvmName("hcqvlblsdufatjep")
    public suspend fun description(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.description = mapped
    }

    /**
     * @param value The end of life date in RFC3339 format of the Gallery Application.
     */
    @JvmName("nygqdratavovmbxx")
    public suspend fun endOfLifeDate(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.endOfLifeDate = mapped
    }

    /**
     * @param value The End User Licence Agreement of the Gallery Application.
     */
    @JvmName("bqptnxqltembopwe")
    public suspend fun eula(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.eula = mapped
    }

    /**
     * @param value The ID of the Shared Image Gallery. Changing this forces a new resource to be created.
     */
    @JvmName("dtvikxhhwbrkbjui")
    public suspend fun galleryId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.galleryId = mapped
    }

    /**
     * @param value The Azure Region where the Gallery Application exists. Changing this forces a new resource to be created.
     */
    @JvmName("ajhttgackdsoxcsg")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value The name of the Gallery Application. Changing this forces a new resource to be created.
     */
    @JvmName("trpkjjnuvrsevylu")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The URI containing the Privacy Statement associated with the Gallery Application.
     */
    @JvmName("sybuftgufocouhwn")
    public suspend fun privacyStatementUri(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.privacyStatementUri = mapped
    }

    /**
     * @param value The URI containing the Release Notes associated with the Gallery Application.
     */
    @JvmName("idocsmjgmsqliumh")
    public suspend fun releaseNoteUri(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.releaseNoteUri = mapped
    }

    /**
     * @param value The type of the Operating System supported for the Gallery Application. Possible values are `Linux` and `Windows`. Changing this forces a new resource to be created.
     */
    @JvmName("hybmclnxxcexopbi")
    public suspend fun supportedOsType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.supportedOsType = mapped
    }

    /**
     * @param value A mapping of tags to assign to the Gallery Application.
     */
    @JvmName("ygtcnjhgghsplmst")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values A mapping of tags to assign to the Gallery Application.
     */
    @JvmName("ljubjlipmuvaifdl")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    internal fun build(): GalleryApplicationArgs = GalleryApplicationArgs(
        description = description,
        endOfLifeDate = endOfLifeDate,
        eula = eula,
        galleryId = galleryId,
        location = location,
        name = name,
        privacyStatementUri = privacyStatementUri,
        releaseNoteUri = releaseNoteUri,
        supportedOsType = supportedOsType,
        tags = tags,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy