![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.awsnative.ecr.kotlin.RepositoryArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.ecr.kotlin
import com.pulumi.awsnative.ecr.RepositoryArgs.builder
import com.pulumi.awsnative.ecr.kotlin.enums.RepositoryImageTagMutability
import com.pulumi.awsnative.ecr.kotlin.inputs.RepositoryEncryptionConfigurationArgs
import com.pulumi.awsnative.ecr.kotlin.inputs.RepositoryEncryptionConfigurationArgsBuilder
import com.pulumi.awsnative.ecr.kotlin.inputs.RepositoryImageScanningConfigurationArgs
import com.pulumi.awsnative.ecr.kotlin.inputs.RepositoryImageScanningConfigurationArgsBuilder
import com.pulumi.awsnative.ecr.kotlin.inputs.RepositoryLifecyclePolicyArgs
import com.pulumi.awsnative.ecr.kotlin.inputs.RepositoryLifecyclePolicyArgsBuilder
import com.pulumi.awsnative.kotlin.inputs.TagArgs
import com.pulumi.awsnative.kotlin.inputs.TagArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Any
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* The ``AWS::ECR::Repository`` resource specifies an Amazon Elastic Container Registry (Amazon ECR) repository, where users can push and pull Docker images, Open Container Initiative (OCI) images, and OCI compatible artifacts. For more information, see [Amazon ECR private repositories](https://docs.aws.amazon.com/AmazonECR/latest/userguide/Repositories.html) in the *Amazon ECR User Guide*.
* ## Example Usage
* ### Example
* No Java example available.
* ### Example
* No Java example available.
* @property emptyOnDelete If true, deleting the repository force deletes the contents of the repository. If false, the repository must be empty before attempting to delete it.
* @property encryptionConfiguration The encryption configuration for the repository. This determines how the contents of your repository are encrypted at rest.
* @property imageScanningConfiguration The image scanning configuration for the repository. This determines whether images are scanned for known vulnerabilities after being pushed to the repository.
* @property imageTagMutability The tag mutability setting for the repository. If this parameter is omitted, the default setting of ``MUTABLE`` will be used which will allow image tags to be overwritten. If ``IMMUTABLE`` is specified, all image tags within the repository will be immutable which will prevent them from being overwritten.
* @property lifecyclePolicy Creates or updates a lifecycle policy. For information about lifecycle policy syntax, see [Lifecycle policy template](https://docs.aws.amazon.com/AmazonECR/latest/userguide/LifecyclePolicies.html).
* @property repositoryName The name to use for the repository. The repository name may be specified on its own (such as ``nginx-web-app``) or it can be prepended with a namespace to group the repository into a category (such as ``project-a/nginx-web-app``). If you don't specify a name, CFNlong generates a unique physical ID and uses that ID for the repository name. For more information, see [Name type](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-name.html).
* The repository name must start with a letter and can only contain lowercase letters, numbers, hyphens, underscores, and forward slashes.
* If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
* @property repositoryPolicyText The JSON repository policy text to apply to the repository. For more information, see [Amazon ECR repository policies](https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policy-examples.html) in the *Amazon Elastic Container Registry User Guide*.
* Search the [CloudFormation User Guide](https://docs.aws.amazon.com/cloudformation/) for `AWS::ECR::Repository` for more information about the expected schema for this property.
* @property tags An array of key-value pairs to apply to this resource.
*/
public data class RepositoryArgs(
public val emptyOnDelete: Output? = null,
public val encryptionConfiguration: Output? = null,
public val imageScanningConfiguration: Output? = null,
public val imageTagMutability: Output? = null,
public val lifecyclePolicy: Output? = null,
public val repositoryName: Output? = null,
public val repositoryPolicyText: Output? = null,
public val tags: Output>? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.ecr.RepositoryArgs =
com.pulumi.awsnative.ecr.RepositoryArgs.builder()
.emptyOnDelete(emptyOnDelete?.applyValue({ args0 -> args0 }))
.encryptionConfiguration(
encryptionConfiguration?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.imageScanningConfiguration(
imageScanningConfiguration?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.imageTagMutability(
imageTagMutability?.applyValue({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
}),
)
.lifecyclePolicy(lifecyclePolicy?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.repositoryName(repositoryName?.applyValue({ args0 -> args0 }))
.repositoryPolicyText(repositoryPolicyText?.applyValue({ args0 -> args0 }))
.tags(
tags?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
})
}),
).build()
}
/**
* Builder for [RepositoryArgs].
*/
@PulumiTagMarker
public class RepositoryArgsBuilder internal constructor() {
private var emptyOnDelete: Output? = null
private var encryptionConfiguration: Output? = null
private var imageScanningConfiguration: Output? = null
private var imageTagMutability: Output? = null
private var lifecyclePolicy: Output? = null
private var repositoryName: Output? = null
private var repositoryPolicyText: Output? = null
private var tags: Output>? = null
/**
* @param value If true, deleting the repository force deletes the contents of the repository. If false, the repository must be empty before attempting to delete it.
*/
@JvmName("jqkfydoayjxeqxxc")
public suspend fun emptyOnDelete(`value`: Output) {
this.emptyOnDelete = value
}
/**
* @param value The encryption configuration for the repository. This determines how the contents of your repository are encrypted at rest.
*/
@JvmName("efsjyegwqklpgpcj")
public suspend fun encryptionConfiguration(`value`: Output) {
this.encryptionConfiguration = value
}
/**
* @param value The image scanning configuration for the repository. This determines whether images are scanned for known vulnerabilities after being pushed to the repository.
*/
@JvmName("jogqryblmwwnxukx")
public suspend fun imageScanningConfiguration(`value`: Output) {
this.imageScanningConfiguration = value
}
/**
* @param value The tag mutability setting for the repository. If this parameter is omitted, the default setting of ``MUTABLE`` will be used which will allow image tags to be overwritten. If ``IMMUTABLE`` is specified, all image tags within the repository will be immutable which will prevent them from being overwritten.
*/
@JvmName("adawrosfdftcfaoe")
public suspend fun imageTagMutability(`value`: Output) {
this.imageTagMutability = value
}
/**
* @param value Creates or updates a lifecycle policy. For information about lifecycle policy syntax, see [Lifecycle policy template](https://docs.aws.amazon.com/AmazonECR/latest/userguide/LifecyclePolicies.html).
*/
@JvmName("pvadvplrttlrogxs")
public suspend fun lifecyclePolicy(`value`: Output) {
this.lifecyclePolicy = value
}
/**
* @param value The name to use for the repository. The repository name may be specified on its own (such as ``nginx-web-app``) or it can be prepended with a namespace to group the repository into a category (such as ``project-a/nginx-web-app``). If you don't specify a name, CFNlong generates a unique physical ID and uses that ID for the repository name. For more information, see [Name type](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-name.html).
* The repository name must start with a letter and can only contain lowercase letters, numbers, hyphens, underscores, and forward slashes.
* If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
*/
@JvmName("yyburfnidqnburdj")
public suspend fun repositoryName(`value`: Output) {
this.repositoryName = value
}
/**
* @param value The JSON repository policy text to apply to the repository. For more information, see [Amazon ECR repository policies](https://docs.aws.amazon.com/AmazonECR/latest/userguide/repository-policy-examples.html) in the *Amazon Elastic Container Registry User Guide*.
* Search the [CloudFormation User Guide](https://docs.aws.amazon.com/cloudformation/) for `AWS::ECR::Repository` for more information about the expected schema for this property.
*/
@JvmName("tvefaewswqwfgqeu")
public suspend fun repositoryPolicyText(`value`: Output) {
this.repositoryPolicyText = value
}
/**
* @param value An array of key-value pairs to apply to this resource.
*/
@JvmName("hptbdfgbvdyvgkuw")
public suspend fun tags(`value`: Output>) {
this.tags = value
}
@JvmName("yjflgwcpibkyduab")
public suspend fun tags(vararg values: Output) {
this.tags = Output.all(values.asList())
}
/**
* @param values An array of key-value pairs to apply to this resource.
*/
@JvmName("wapgxfomsuipqwgf")
public suspend fun tags(values: List
© 2015 - 2025 Weber Informatics LLC | Privacy Policy