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

com.pulumi.gcp.compute.kotlin.Image.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: 8.12.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.compute.kotlin

import com.pulumi.core.Output
import com.pulumi.gcp.compute.kotlin.outputs.ImageGuestOsFeature
import com.pulumi.gcp.compute.kotlin.outputs.ImageImageEncryptionKey
import com.pulumi.gcp.compute.kotlin.outputs.ImageRawDisk
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Boolean
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import com.pulumi.gcp.compute.kotlin.outputs.ImageGuestOsFeature.Companion.toKotlin as imageGuestOsFeatureToKotlin
import com.pulumi.gcp.compute.kotlin.outputs.ImageImageEncryptionKey.Companion.toKotlin as imageImageEncryptionKeyToKotlin
import com.pulumi.gcp.compute.kotlin.outputs.ImageRawDisk.Companion.toKotlin as imageRawDiskToKotlin

/**
 * Builder for [Image].
 */
@PulumiTagMarker
public class ImageResourceBuilder internal constructor() {
    public var name: String? = null

    public var args: ImageArgs = ImageArgs()

    public var opts: CustomResourceOptions = CustomResourceOptions()

    /**
     * @param name The _unique_ name of the resulting resource.
     */
    public fun name(`value`: String) {
        this.name = value
    }

    /**
     * @param block The arguments to use to populate this resource's properties.
     */
    public suspend fun args(block: suspend ImageArgsBuilder.() -> Unit) {
        val builder = ImageArgsBuilder()
        block(builder)
        this.args = builder.build()
    }

    /**
     * @param block A bag of options that control this resource's behavior.
     */
    public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
        this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
    }

    internal fun build(): Image {
        val builtJavaResource = com.pulumi.gcp.compute.Image(
            this.name,
            this.args.toJava(),
            this.opts.toJava(),
        )
        return Image(builtJavaResource)
    }
}

/**
 * Represents an Image resource.
 * Google Compute Engine uses operating system images to create the root
 * persistent disks for your instances. You specify an image when you create
 * an instance. Images contain a boot loader, an operating system, and a
 * root file system. Linux operating system images are also capable of
 * running containers on Compute Engine.
 * Images can be either public or custom.
 * Public images are provided and maintained by Google, open-source
 * communities, and third-party vendors. By default, all projects have
 * access to these images and can use them to create instances.  Custom
 * images are available only to your project. You can create a custom image
 * from root persistent disks and other images. Then, use the custom image
 * to create an instance.
 * To get more information about Image, see:
 * * [API documentation](https://cloud.google.com/compute/docs/reference/v1/images)
 * * How-to Guides
 *     * [Official Documentation](https://cloud.google.com/compute/docs/images)
 * ## Example Usage
 * ### Image Basic
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 * const example = new gcp.compute.Image("example", {
 *     name: "example-image",
 *     rawDisk: {
 *         source: "https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *     },
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_gcp as gcp
 * example = gcp.compute.Image("example",
 *     name="example-image",
 *     raw_disk=gcp.compute.ImageRawDiskArgs(
 *         source="https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *     ))
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Gcp = Pulumi.Gcp;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Gcp.Compute.Image("example", new()
 *     {
 *         Name = "example-image",
 *         RawDisk = new Gcp.Compute.Inputs.ImageRawDiskArgs
 *         {
 *             Source = "https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/compute"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := compute.NewImage(ctx, "example", &compute.ImageArgs{
 * 			Name: pulumi.String("example-image"),
 * 			RawDisk: &compute.ImageRawDiskArgs{
 * 				Source: pulumi.String("https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz"),
 * 			},
 * 		})
 * 		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.gcp.compute.Image;
 * import com.pulumi.gcp.compute.ImageArgs;
 * import com.pulumi.gcp.compute.inputs.ImageRawDiskArgs;
 * 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 Image("example", ImageArgs.builder()
 *             .name("example-image")
 *             .rawDisk(ImageRawDiskArgs.builder()
 *                 .source("https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz")
 *                 .build())
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: gcp:compute:Image
 *     properties:
 *       name: example-image
 *       rawDisk:
 *         source: https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz
 * ```
 * 
 * ### Image Guest Os
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 * const example = new gcp.compute.Image("example", {
 *     name: "example-image",
 *     rawDisk: {
 *         source: "https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *     },
 *     guestOsFeatures: [
 *         {
 *             type: "SECURE_BOOT",
 *         },
 *         {
 *             type: "MULTI_IP_SUBNET",
 *         },
 *     ],
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_gcp as gcp
 * example = gcp.compute.Image("example",
 *     name="example-image",
 *     raw_disk=gcp.compute.ImageRawDiskArgs(
 *         source="https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *     ),
 *     guest_os_features=[
 *         gcp.compute.ImageGuestOsFeatureArgs(
 *             type="SECURE_BOOT",
 *         ),
 *         gcp.compute.ImageGuestOsFeatureArgs(
 *             type="MULTI_IP_SUBNET",
 *         ),
 *     ])
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Gcp = Pulumi.Gcp;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Gcp.Compute.Image("example", new()
 *     {
 *         Name = "example-image",
 *         RawDisk = new Gcp.Compute.Inputs.ImageRawDiskArgs
 *         {
 *             Source = "https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *         },
 *         GuestOsFeatures = new[]
 *         {
 *             new Gcp.Compute.Inputs.ImageGuestOsFeatureArgs
 *             {
 *                 Type = "SECURE_BOOT",
 *             },
 *             new Gcp.Compute.Inputs.ImageGuestOsFeatureArgs
 *             {
 *                 Type = "MULTI_IP_SUBNET",
 *             },
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/compute"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := compute.NewImage(ctx, "example", &compute.ImageArgs{
 * 			Name: pulumi.String("example-image"),
 * 			RawDisk: &compute.ImageRawDiskArgs{
 * 				Source: pulumi.String("https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz"),
 * 			},
 * 			GuestOsFeatures: compute.ImageGuestOsFeatureArray{
 * 				&compute.ImageGuestOsFeatureArgs{
 * 					Type: pulumi.String("SECURE_BOOT"),
 * 				},
 * 				&compute.ImageGuestOsFeatureArgs{
 * 					Type: pulumi.String("MULTI_IP_SUBNET"),
 * 				},
 * 			},
 * 		})
 * 		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.gcp.compute.Image;
 * import com.pulumi.gcp.compute.ImageArgs;
 * import com.pulumi.gcp.compute.inputs.ImageRawDiskArgs;
 * import com.pulumi.gcp.compute.inputs.ImageGuestOsFeatureArgs;
 * 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 Image("example", ImageArgs.builder()
 *             .name("example-image")
 *             .rawDisk(ImageRawDiskArgs.builder()
 *                 .source("https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz")
 *                 .build())
 *             .guestOsFeatures(
 *                 ImageGuestOsFeatureArgs.builder()
 *                     .type("SECURE_BOOT")
 *                     .build(),
 *                 ImageGuestOsFeatureArgs.builder()
 *                     .type("MULTI_IP_SUBNET")
 *                     .build())
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: gcp:compute:Image
 *     properties:
 *       name: example-image
 *       rawDisk:
 *         source: https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz
 *       guestOsFeatures:
 *         - type: SECURE_BOOT
 *         - type: MULTI_IP_SUBNET
 * ```
 * 
 * ### Image Basic Storage Location
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 * const example = new gcp.compute.Image("example", {
 *     name: "example-sl-image",
 *     rawDisk: {
 *         source: "https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *     },
 *     storageLocations: ["us-central1"],
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_gcp as gcp
 * example = gcp.compute.Image("example",
 *     name="example-sl-image",
 *     raw_disk=gcp.compute.ImageRawDiskArgs(
 *         source="https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *     ),
 *     storage_locations=["us-central1"])
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Gcp = Pulumi.Gcp;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Gcp.Compute.Image("example", new()
 *     {
 *         Name = "example-sl-image",
 *         RawDisk = new Gcp.Compute.Inputs.ImageRawDiskArgs
 *         {
 *             Source = "https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz",
 *         },
 *         StorageLocations = new[]
 *         {
 *             "us-central1",
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/compute"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := compute.NewImage(ctx, "example", &compute.ImageArgs{
 * 			Name: pulumi.String("example-sl-image"),
 * 			RawDisk: &compute.ImageRawDiskArgs{
 * 				Source: pulumi.String("https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz"),
 * 			},
 * 			StorageLocations: pulumi.StringArray{
 * 				pulumi.String("us-central1"),
 * 			},
 * 		})
 * 		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.gcp.compute.Image;
 * import com.pulumi.gcp.compute.ImageArgs;
 * import com.pulumi.gcp.compute.inputs.ImageRawDiskArgs;
 * 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 Image("example", ImageArgs.builder()
 *             .name("example-sl-image")
 *             .rawDisk(ImageRawDiskArgs.builder()
 *                 .source("https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz")
 *                 .build())
 *             .storageLocations("us-central1")
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: gcp:compute:Image
 *     properties:
 *       name: example-sl-image
 *       rawDisk:
 *         source: https://storage.googleapis.com/bosh-gce-raw-stemcells/bosh-stemcell-97.98-google-kvm-ubuntu-xenial-go_agent-raw-1557960142.tar.gz
 *       storageLocations:
 *         - us-central1
 * ```
 * 
 * ## Import
 * Image can be imported using any of these accepted formats:
 * * `projects/{{project}}/global/images/{{name}}`
 * * `{{project}}/{{name}}`
 * * `{{name}}`
 * When using the `pulumi import` command, Image can be imported using one of the formats above. For example:
 * ```sh
 * $ pulumi import gcp:compute/image:Image default projects/{{project}}/global/images/{{name}}
 * ```
 * ```sh
 * $ pulumi import gcp:compute/image:Image default {{project}}/{{name}}
 * ```
 * ```sh
 * $ pulumi import gcp:compute/image:Image default {{name}}
 * ```
 */
public class Image internal constructor(
    override val javaResource: com.pulumi.gcp.compute.Image,
) : KotlinCustomResource(javaResource, ImageMapper) {
    /**
     * Size of the image tar.gz archive stored in Google Cloud Storage (in
     * bytes).
     */
    public val archiveSizeBytes: Output
        get() = javaResource.archiveSizeBytes().applyValue({ args0 -> args0 })

    /**
     * Creation timestamp in RFC3339 text format.
     */
    public val creationTimestamp: Output
        get() = javaResource.creationTimestamp().applyValue({ args0 -> args0 })

    /**
     * An optional description of this resource. Provide this property when
     * you create the resource.
     */
    public val description: Output?
        get() = javaResource.description().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Size of the image when restored onto a persistent disk (in GB).
     */
    public val diskSizeGb: Output
        get() = javaResource.diskSizeGb().applyValue({ args0 -> args0 })

    /**
     * All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
     */
    public val effectiveLabels: Output>
        get() = javaResource.effectiveLabels().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.key.to(args0.value)
            }).toMap()
        })

    /**
     * The name of the image family to which this image belongs. You can
     * create disks by specifying an image family instead of a specific
     * image name. The image family always returns its latest image that is
     * not deprecated. The name of the image family must comply with
     * RFC1035.
     */
    public val family: Output?
        get() = javaResource.family().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })

    /**
     * A list of features to enable on the guest operating system.
     * Applicable only for bootable images.
     * Structure is documented below.
     */
    public val guestOsFeatures: Output>
        get() = javaResource.guestOsFeatures().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> imageGuestOsFeatureToKotlin(args0) })
            })
        })

    /**
     * Encrypts the image using a customer-supplied encryption key.
     * After you encrypt an image with a customer-supplied key, you must
     * provide the same key if you use the image later (e.g. to create a
     * disk from the image)
     * Structure is documented below.
     */
    public val imageEncryptionKey: Output?
        get() = javaResource.imageEncryptionKey().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> imageImageEncryptionKeyToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * The fingerprint used for optimistic locking of this resource. Used
     * internally during updates.
     */
    public val labelFingerprint: Output
        get() = javaResource.labelFingerprint().applyValue({ args0 -> args0 })

    /**
     * Labels to apply to this Image.
     * **Note**: This field is non-authoritative, and will only manage the labels present in your configuration.
     * Please refer to the field `effective_labels` for all of the labels present on the resource.
     */
    public val labels: Output>?
        get() = javaResource.labels().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 ->
                    args0.key.to(args0.value)
                }).toMap()
            }).orElse(null)
        })

    /**
     * Any applicable license URI.
     */
    public val licenses: Output>
        get() = javaResource.licenses().applyValue({ args0 -> args0.map({ args0 -> args0 }) })

    /**
     * Name of the resource; provided by the client when the resource is
     * created. The name must be 1-63 characters long, and comply with
     * RFC1035. Specifically, the name must be 1-63 characters long and
     * match the regular expression `a-z?` which means
     * the first character must be a lowercase letter, and all following
     * characters must be a dash, lowercase letter, or digit, except the
     * last character, which cannot be a dash.
     * - - -
     */
    public val name: Output
        get() = javaResource.name().applyValue({ args0 -> args0 })

    /**
     * The ID of the project in which the resource belongs.
     * If it is not provided, the provider project is used.
     */
    public val project: Output
        get() = javaResource.project().applyValue({ args0 -> args0 })

    /**
     * The combination of labels configured directly on the resource
     * and default labels configured on the provider.
     */
    public val pulumiLabels: Output>
        get() = javaResource.pulumiLabels().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.key.to(args0.value)
            }).toMap()
        })

    /**
     * The parameters of the raw disk image.
     * Structure is documented below.
     */
    public val rawDisk: Output?
        get() = javaResource.rawDisk().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    imageRawDiskToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * The URI of the created resource.
     */
    public val selfLink: Output
        get() = javaResource.selfLink().applyValue({ args0 -> args0 })

    /**
     * The source disk to create this image based on.
     * You must provide either this property or the
     * rawDisk.source property but not both to create an image.
     */
    public val sourceDisk: Output?
        get() = javaResource.sourceDisk().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * URL of the source image used to create this image. In order to create an image, you must provide the full or partial
     * URL of one of the following:
     * * The selfLink URL
     * * This property
     * * The rawDisk.source URL
     * * The sourceDisk URL
     */
    public val sourceImage: Output?
        get() = javaResource.sourceImage().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * URL of the source snapshot used to create this image.
     * In order to create an image, you must provide the full or partial URL of one of the following:
     * * The selfLink URL
     * * This property
     * * The sourceImage URL
     * * The rawDisk.source URL
     * * The sourceDisk URL
     */
    public val sourceSnapshot: Output?
        get() = javaResource.sourceSnapshot().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Cloud Storage bucket storage location of the image
     * (regional or multi-regional).
     * Reference link: https://cloud.google.com/compute/docs/reference/rest/v1/images
     */
    public val storageLocations: Output>
        get() = javaResource.storageLocations().applyValue({ args0 -> args0.map({ args0 -> args0 }) })
}

public object ImageMapper : ResourceMapper {
    override fun supportsMappingOfType(javaResource: Resource): Boolean =
        com.pulumi.gcp.compute.Image::class == javaResource::class

    override fun map(javaResource: Resource): Image = Image(
        javaResource as
            com.pulumi.gcp.compute.Image,
    )
}

/**
 * @see [Image].
 * @param name The _unique_ name of the resulting resource.
 * @param block Builder for [Image].
 */
public suspend fun image(name: String, block: suspend ImageResourceBuilder.() -> Unit): Image {
    val builder = ImageResourceBuilder()
    builder.name(name)
    block(builder)
    return builder.build()
}

/**
 * @see [Image].
 * @param name The _unique_ name of the resulting resource.
 */
public fun image(name: String): Image {
    val builder = ImageResourceBuilder()
    builder.name(name)
    return builder.build()
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy