com.pulumi.awsnative.m2.kotlin.Environment.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.m2.kotlin
import com.pulumi.awsnative.m2.kotlin.enums.EnvironmentEngineType
import com.pulumi.awsnative.m2.kotlin.outputs.EnvironmentHighAvailabilityConfig
import com.pulumi.awsnative.m2.kotlin.outputs.EnvironmentStorageConfiguration
import com.pulumi.core.Output
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.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import com.pulumi.awsnative.m2.kotlin.enums.EnvironmentEngineType.Companion.toKotlin as environmentEngineTypeToKotlin
import com.pulumi.awsnative.m2.kotlin.outputs.EnvironmentHighAvailabilityConfig.Companion.toKotlin as environmentHighAvailabilityConfigToKotlin
import com.pulumi.awsnative.m2.kotlin.outputs.EnvironmentStorageConfiguration.Companion.toKotlin as environmentStorageConfigurationToKotlin
/**
* Builder for [Environment].
*/
@PulumiTagMarker
public class EnvironmentResourceBuilder internal constructor() {
public var name: String? = null
public var args: EnvironmentArgs = EnvironmentArgs()
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 EnvironmentArgsBuilder.() -> Unit) {
val builder = EnvironmentArgsBuilder()
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(): Environment {
val builtJavaResource = com.pulumi.awsnative.m2.Environment(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return Environment(builtJavaResource)
}
}
/**
* Represents a runtime environment that can run migrated mainframe applications.
*/
public class Environment internal constructor(
override val javaResource: com.pulumi.awsnative.m2.Environment,
) : KotlinCustomResource(javaResource, EnvironmentMapper) {
/**
* The description of the environment.
*/
public val description: Output?
get() = javaResource.description().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The target platform for the runtime environment.
*/
public val engineType: Output
get() = javaResource.engineType().applyValue({ args0 ->
args0.let({ args0 ->
environmentEngineTypeToKotlin(args0)
})
})
/**
* The version of the runtime engine for the environment.
*/
public val engineVersion: Output?
get() = javaResource.engineVersion().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The Amazon Resource Name (ARN) of the runtime environment.
*/
public val environmentArn: Output
get() = javaResource.environmentArn().applyValue({ args0 -> args0 })
/**
* The unique identifier of the environment.
*/
public val environmentId: Output
get() = javaResource.environmentId().applyValue({ args0 -> args0 })
/**
* Defines the details of a high availability configuration.
*/
public val highAvailabilityConfig: Output?
get() = javaResource.highAvailabilityConfig().applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> environmentHighAvailabilityConfigToKotlin(args0) })
}).orElse(null)
})
/**
* The type of instance underlying the environment.
*/
public val instanceType: Output
get() = javaResource.instanceType().applyValue({ args0 -> args0 })
/**
* The ID or the Amazon Resource Name (ARN) of the customer managed KMS Key used for encrypting environment-related resources.
*/
public val kmsKeyId: Output?
get() = javaResource.kmsKeyId().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* The name of the environment.
*/
public val name: Output
get() = javaResource.name().applyValue({ args0 -> args0 })
/**
* Configures a desired maintenance window for the environment. If you do not provide a value, a random system-generated value will be assigned.
*/
public val preferredMaintenanceWindow: Output?
get() = javaResource.preferredMaintenanceWindow().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* Specifies whether the environment is publicly accessible.
*/
public val publiclyAccessible: Output?
get() = javaResource.publiclyAccessible().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The list of security groups for the VPC associated with this environment.
*/
public val securityGroupIds: Output>?
get() = javaResource.securityGroupIds().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 -> args0 })
}).orElse(null)
})
/**
* The storage configurations defined for the runtime environment.
*/
public val storageConfigurations: Output>?
get() = javaResource.storageConfigurations().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
environmentStorageConfigurationToKotlin(args0)
})
})
}).orElse(null)
})
/**
* The unique identifiers of the subnets assigned to this runtime environment.
*/
public val subnetIds: Output>?
get() = javaResource.subnetIds().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 ->
args0
})
}).orElse(null)
})
/**
* Tags associated to this environment.
*/
public val tags: Output