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

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

package com.pulumi.gcp.compute.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.compute.inputs.DiskDiskEncryptionKeyArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName

/**
 *
 * @property kmsKeySelfLink The self link of the encryption key used to encrypt the disk. Also called KmsKeyName
 * in the cloud console. Your project's Compute Engine System service account
 * (`service-{{PROJECT_NUMBER}}@compute-system.iam.gserviceaccount.com`) must have
 * `roles/cloudkms.cryptoKeyEncrypterDecrypter` to use this feature.
 * See https://cloud.google.com/compute/docs/disks/customer-managed-encryption#encrypt_a_new_persistent_disk_with_your_own_keys
 * @property kmsKeyServiceAccount The service account used for the encryption request for the given KMS key.
 * If absent, the Compute Engine Service Agent service account is used.
 * @property rawKey Specifies a 256-bit customer-supplied encryption key, encoded in
 * RFC 4648 base64 to either encrypt or decrypt this resource.
 * **Note**: This property is sensitive and will not be displayed in the plan.
 * @property rsaEncryptedKey Specifies an RFC 4648 base64 encoded, RSA-wrapped 2048-bit
 * customer-supplied encryption key to either encrypt or decrypt
 * this resource. You can provide either the rawKey or the rsaEncryptedKey.
 * **Note**: This property is sensitive and will not be displayed in the plan.
 * @property sha256 (Output)
 * The RFC 4648 base64 encoded SHA-256 hash of the customer-supplied
 * encryption key that protects this resource.
 */
public data class DiskDiskEncryptionKeyArgs(
    public val kmsKeySelfLink: Output? = null,
    public val kmsKeyServiceAccount: Output? = null,
    public val rawKey: Output? = null,
    public val rsaEncryptedKey: Output? = null,
    public val sha256: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.compute.inputs.DiskDiskEncryptionKeyArgs =
        com.pulumi.gcp.compute.inputs.DiskDiskEncryptionKeyArgs.builder()
            .kmsKeySelfLink(kmsKeySelfLink?.applyValue({ args0 -> args0 }))
            .kmsKeyServiceAccount(kmsKeyServiceAccount?.applyValue({ args0 -> args0 }))
            .rawKey(rawKey?.applyValue({ args0 -> args0 }))
            .rsaEncryptedKey(rsaEncryptedKey?.applyValue({ args0 -> args0 }))
            .sha256(sha256?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [DiskDiskEncryptionKeyArgs].
 */
@PulumiTagMarker
public class DiskDiskEncryptionKeyArgsBuilder internal constructor() {
    private var kmsKeySelfLink: Output? = null

    private var kmsKeyServiceAccount: Output? = null

    private var rawKey: Output? = null

    private var rsaEncryptedKey: Output? = null

    private var sha256: Output? = null

    /**
     * @param value The self link of the encryption key used to encrypt the disk. Also called KmsKeyName
     * in the cloud console. Your project's Compute Engine System service account
     * (`service-{{PROJECT_NUMBER}}@compute-system.iam.gserviceaccount.com`) must have
     * `roles/cloudkms.cryptoKeyEncrypterDecrypter` to use this feature.
     * See https://cloud.google.com/compute/docs/disks/customer-managed-encryption#encrypt_a_new_persistent_disk_with_your_own_keys
     */
    @JvmName("qlaafvmgjnxnrdkb")
    public suspend fun kmsKeySelfLink(`value`: Output) {
        this.kmsKeySelfLink = value
    }

    /**
     * @param value The service account used for the encryption request for the given KMS key.
     * If absent, the Compute Engine Service Agent service account is used.
     */
    @JvmName("hmfplkrxgxgktsfg")
    public suspend fun kmsKeyServiceAccount(`value`: Output) {
        this.kmsKeyServiceAccount = value
    }

    /**
     * @param value Specifies a 256-bit customer-supplied encryption key, encoded in
     * RFC 4648 base64 to either encrypt or decrypt this resource.
     * **Note**: This property is sensitive and will not be displayed in the plan.
     */
    @JvmName("mclygfeeenhgydav")
    public suspend fun rawKey(`value`: Output) {
        this.rawKey = value
    }

    /**
     * @param value Specifies an RFC 4648 base64 encoded, RSA-wrapped 2048-bit
     * customer-supplied encryption key to either encrypt or decrypt
     * this resource. You can provide either the rawKey or the rsaEncryptedKey.
     * **Note**: This property is sensitive and will not be displayed in the plan.
     */
    @JvmName("kkdpyksanyksuxlr")
    public suspend fun rsaEncryptedKey(`value`: Output) {
        this.rsaEncryptedKey = value
    }

    /**
     * @param value (Output)
     * The RFC 4648 base64 encoded SHA-256 hash of the customer-supplied
     * encryption key that protects this resource.
     */
    @JvmName("iarallwqtagngdwh")
    public suspend fun sha256(`value`: Output) {
        this.sha256 = value
    }

    /**
     * @param value The self link of the encryption key used to encrypt the disk. Also called KmsKeyName
     * in the cloud console. Your project's Compute Engine System service account
     * (`service-{{PROJECT_NUMBER}}@compute-system.iam.gserviceaccount.com`) must have
     * `roles/cloudkms.cryptoKeyEncrypterDecrypter` to use this feature.
     * See https://cloud.google.com/compute/docs/disks/customer-managed-encryption#encrypt_a_new_persistent_disk_with_your_own_keys
     */
    @JvmName("tkcufjywoyvpcpas")
    public suspend fun kmsKeySelfLink(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.kmsKeySelfLink = mapped
    }

    /**
     * @param value The service account used for the encryption request for the given KMS key.
     * If absent, the Compute Engine Service Agent service account is used.
     */
    @JvmName("wxkfjtaxbhtmaatr")
    public suspend fun kmsKeyServiceAccount(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.kmsKeyServiceAccount = mapped
    }

    /**
     * @param value Specifies a 256-bit customer-supplied encryption key, encoded in
     * RFC 4648 base64 to either encrypt or decrypt this resource.
     * **Note**: This property is sensitive and will not be displayed in the plan.
     */
    @JvmName("xmpqrbpxnqnrlfah")
    public suspend fun rawKey(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.rawKey = mapped
    }

    /**
     * @param value Specifies an RFC 4648 base64 encoded, RSA-wrapped 2048-bit
     * customer-supplied encryption key to either encrypt or decrypt
     * this resource. You can provide either the rawKey or the rsaEncryptedKey.
     * **Note**: This property is sensitive and will not be displayed in the plan.
     */
    @JvmName("pcbucbmikokblbbe")
    public suspend fun rsaEncryptedKey(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.rsaEncryptedKey = mapped
    }

    /**
     * @param value (Output)
     * The RFC 4648 base64 encoded SHA-256 hash of the customer-supplied
     * encryption key that protects this resource.
     */
    @JvmName("vwcvkrqhhxdhyrrx")
    public suspend fun sha256(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sha256 = mapped
    }

    internal fun build(): DiskDiskEncryptionKeyArgs = DiskDiskEncryptionKeyArgs(
        kmsKeySelfLink = kmsKeySelfLink,
        kmsKeyServiceAccount = kmsKeyServiceAccount,
        rawKey = rawKey,
        rsaEncryptedKey = rsaEncryptedKey,
        sha256 = sha256,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy