com.pulumi.awsnative.iot.kotlin.CertificateArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-native-kotlin Show documentation
Show all versions of pulumi-aws-native-kotlin Show documentation
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.awsnative.iot.kotlin
import com.pulumi.awsnative.iot.CertificateArgs.builder
import com.pulumi.awsnative.iot.kotlin.enums.CertificateMode
import com.pulumi.awsnative.iot.kotlin.enums.CertificateStatus
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
* Use the AWS::IoT::Certificate resource to declare an AWS IoT X.509 certificate.
* @property caCertificatePem The CA certificate used to sign the device certificate being registered, not available when CertificateMode is SNI_ONLY.
* @property certificateMode Specifies which mode of certificate registration to use with this resource. Valid options are DEFAULT with CaCertificatePem and CertificatePem, SNI_ONLY with CertificatePem, and Default with CertificateSigningRequest.
* `DEFAULT` : A certificate in `DEFAULT` mode is either generated by AWS IoT Core or registered with an issuer certificate authority (CA). Devices with certificates in `DEFAULT` mode aren't required to send the Server Name Indication (SNI) extension when connecting to AWS IoT Core . However, to use features such as custom domains and VPC endpoints, we recommend that you use the SNI extension when connecting to AWS IoT Core .
* `SNI_ONLY` : A certificate in `SNI_ONLY` mode is registered without an issuer CA. Devices with certificates in `SNI_ONLY` mode must send the SNI extension when connecting to AWS IoT Core .
* @property certificatePem The certificate data in PEM format. Requires SNI_ONLY for the certificate mode or the accompanying CACertificatePem for registration.
* @property certificateSigningRequest The certificate signing request (CSR).
* @property status The status of the certificate.
* Valid values are ACTIVE, INACTIVE, REVOKED, PENDING_TRANSFER, and PENDING_ACTIVATION.
* The status value REGISTER_INACTIVE is deprecated and should not be used.
*/
public data class CertificateArgs(
public val caCertificatePem: Output? = null,
public val certificateMode: Output? = null,
public val certificatePem: Output? = null,
public val certificateSigningRequest: Output? = null,
public val status: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.iot.CertificateArgs =
com.pulumi.awsnative.iot.CertificateArgs.builder()
.caCertificatePem(caCertificatePem?.applyValue({ args0 -> args0 }))
.certificateMode(certificateMode?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.certificatePem(certificatePem?.applyValue({ args0 -> args0 }))
.certificateSigningRequest(certificateSigningRequest?.applyValue({ args0 -> args0 }))
.status(status?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) })).build()
}
/**
* Builder for [CertificateArgs].
*/
@PulumiTagMarker
public class CertificateArgsBuilder internal constructor() {
private var caCertificatePem: Output? = null
private var certificateMode: Output? = null
private var certificatePem: Output? = null
private var certificateSigningRequest: Output? = null
private var status: Output? = null
/**
* @param value The CA certificate used to sign the device certificate being registered, not available when CertificateMode is SNI_ONLY.
*/
@JvmName("rikxixkoixiwgfnq")
public suspend fun caCertificatePem(`value`: Output) {
this.caCertificatePem = value
}
/**
* @param value Specifies which mode of certificate registration to use with this resource. Valid options are DEFAULT with CaCertificatePem and CertificatePem, SNI_ONLY with CertificatePem, and Default with CertificateSigningRequest.
* `DEFAULT` : A certificate in `DEFAULT` mode is either generated by AWS IoT Core or registered with an issuer certificate authority (CA). Devices with certificates in `DEFAULT` mode aren't required to send the Server Name Indication (SNI) extension when connecting to AWS IoT Core . However, to use features such as custom domains and VPC endpoints, we recommend that you use the SNI extension when connecting to AWS IoT Core .
* `SNI_ONLY` : A certificate in `SNI_ONLY` mode is registered without an issuer CA. Devices with certificates in `SNI_ONLY` mode must send the SNI extension when connecting to AWS IoT Core .
*/
@JvmName("pgfwmcgiskfpmpid")
public suspend fun certificateMode(`value`: Output) {
this.certificateMode = value
}
/**
* @param value The certificate data in PEM format. Requires SNI_ONLY for the certificate mode or the accompanying CACertificatePem for registration.
*/
@JvmName("walsrvcejdrmuklq")
public suspend fun certificatePem(`value`: Output) {
this.certificatePem = value
}
/**
* @param value The certificate signing request (CSR).
*/
@JvmName("rqwotatkkuwldhdj")
public suspend fun certificateSigningRequest(`value`: Output) {
this.certificateSigningRequest = value
}
/**
* @param value The status of the certificate.
* Valid values are ACTIVE, INACTIVE, REVOKED, PENDING_TRANSFER, and PENDING_ACTIVATION.
* The status value REGISTER_INACTIVE is deprecated and should not be used.
*/
@JvmName("bagnkojgfmdmnomm")
public suspend fun status(`value`: Output) {
this.status = value
}
/**
* @param value The CA certificate used to sign the device certificate being registered, not available when CertificateMode is SNI_ONLY.
*/
@JvmName("ulfhovvexpohhesl")
public suspend fun caCertificatePem(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.caCertificatePem = mapped
}
/**
* @param value Specifies which mode of certificate registration to use with this resource. Valid options are DEFAULT with CaCertificatePem and CertificatePem, SNI_ONLY with CertificatePem, and Default with CertificateSigningRequest.
* `DEFAULT` : A certificate in `DEFAULT` mode is either generated by AWS IoT Core or registered with an issuer certificate authority (CA). Devices with certificates in `DEFAULT` mode aren't required to send the Server Name Indication (SNI) extension when connecting to AWS IoT Core . However, to use features such as custom domains and VPC endpoints, we recommend that you use the SNI extension when connecting to AWS IoT Core .
* `SNI_ONLY` : A certificate in `SNI_ONLY` mode is registered without an issuer CA. Devices with certificates in `SNI_ONLY` mode must send the SNI extension when connecting to AWS IoT Core .
*/
@JvmName("styxsfvpswspnqoe")
public suspend fun certificateMode(`value`: CertificateMode?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.certificateMode = mapped
}
/**
* @param value The certificate data in PEM format. Requires SNI_ONLY for the certificate mode or the accompanying CACertificatePem for registration.
*/
@JvmName("kyspwttlwufnctcv")
public suspend fun certificatePem(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.certificatePem = mapped
}
/**
* @param value The certificate signing request (CSR).
*/
@JvmName("hvhjsysfsaujifnk")
public suspend fun certificateSigningRequest(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.certificateSigningRequest = mapped
}
/**
* @param value The status of the certificate.
* Valid values are ACTIVE, INACTIVE, REVOKED, PENDING_TRANSFER, and PENDING_ACTIVATION.
* The status value REGISTER_INACTIVE is deprecated and should not be used.
*/
@JvmName("blbbjabhusdjnnkd")
public suspend fun status(`value`: CertificateStatus?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.status = mapped
}
internal fun build(): CertificateArgs = CertificateArgs(
caCertificatePem = caCertificatePem,
certificateMode = certificateMode,
certificatePem = certificatePem,
certificateSigningRequest = certificateSigningRequest,
status = status,
)
}