Class CfnRepositoryCreationTemplateProps.Builder
java.lang.Object
software.amazon.awscdk.services.ecr.CfnRepositoryCreationTemplateProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnRepositoryCreationTemplateProps>
- Enclosing interface:
CfnRepositoryCreationTemplateProps
@Stability(Stable)
public static final class CfnRepositoryCreationTemplateProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnRepositoryCreationTemplateProps>
A builder for
CfnRepositoryCreationTemplateProps
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionappliedFor
(List<String> appliedFor) Sets the value ofCfnRepositoryCreationTemplateProps.getAppliedFor()
build()
Builds the configured instance.description
(String description) Sets the value ofCfnRepositoryCreationTemplateProps.getDescription()
encryptionConfiguration
(IResolvable encryptionConfiguration) Sets the value ofCfnRepositoryCreationTemplateProps.getEncryptionConfiguration()
encryptionConfiguration
(CfnRepositoryCreationTemplate.EncryptionConfigurationProperty encryptionConfiguration) Sets the value ofCfnRepositoryCreationTemplateProps.getEncryptionConfiguration()
imageTagMutability
(String imageTagMutability) Sets the value ofCfnRepositoryCreationTemplateProps.getImageTagMutability()
lifecyclePolicy
(String lifecyclePolicy) Sets the value ofCfnRepositoryCreationTemplateProps.getLifecyclePolicy()
Sets the value ofCfnRepositoryCreationTemplateProps.getPrefix()
repositoryPolicy
(String repositoryPolicy) Sets the value ofCfnRepositoryCreationTemplateProps.getRepositoryPolicy()
resourceTags
(List<? extends Object> resourceTags) Sets the value ofCfnRepositoryCreationTemplateProps.getResourceTags()
resourceTags
(IResolvable resourceTags) Sets the value ofCfnRepositoryCreationTemplateProps.getResourceTags()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
appliedFor
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder appliedFor(List<String> appliedFor) Sets the value ofCfnRepositoryCreationTemplateProps.getAppliedFor()
- Parameters:
appliedFor
- A list of enumerable Strings representing the repository creation scenarios that the template will apply towards. This parameter is required.- Returns:
this
-
prefix
Sets the value ofCfnRepositoryCreationTemplateProps.getPrefix()
- Parameters:
prefix
- The prefix use to match the repository name and apply the template. This parameter is required.- Returns:
this
-
description
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder description(String description) Sets the value ofCfnRepositoryCreationTemplateProps.getDescription()
- Parameters:
description
- The description of the template.- Returns:
this
-
encryptionConfiguration
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder encryptionConfiguration(IResolvable encryptionConfiguration) Sets the value ofCfnRepositoryCreationTemplateProps.getEncryptionConfiguration()
- Parameters:
encryptionConfiguration
- The encryption configuration for the repository. This determines how the contents of your repository are encrypted at rest. By default, when no encryption configuration is set or theAES256
encryption type is used, Amazon ECR uses server-side encryption with Amazon S3-managed encryption keys which encrypts your data at rest using an AES-256 encryption algorithm. This does not require any action on your part.For more control over the encryption of the contents of your repository, you can use server-side encryption with AWS Key Management Service key stored in AWS Key Management Service ( AWS KMS ) to encrypt your images. For more information, see Amazon ECR encryption at rest in the Amazon Elastic Container Registry User Guide .
- Returns:
this
-
encryptionConfiguration
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder encryptionConfiguration(CfnRepositoryCreationTemplate.EncryptionConfigurationProperty encryptionConfiguration) Sets the value ofCfnRepositoryCreationTemplateProps.getEncryptionConfiguration()
- Parameters:
encryptionConfiguration
- The encryption configuration for the repository. This determines how the contents of your repository are encrypted at rest. By default, when no encryption configuration is set or theAES256
encryption type is used, Amazon ECR uses server-side encryption with Amazon S3-managed encryption keys which encrypts your data at rest using an AES-256 encryption algorithm. This does not require any action on your part.For more control over the encryption of the contents of your repository, you can use server-side encryption with AWS Key Management Service key stored in AWS Key Management Service ( AWS KMS ) to encrypt your images. For more information, see Amazon ECR encryption at rest in the Amazon Elastic Container Registry User Guide .
- Returns:
this
-
imageTagMutability
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder imageTagMutability(String imageTagMutability) Sets the value ofCfnRepositoryCreationTemplateProps.getImageTagMutability()
- Parameters:
imageTagMutability
- The image tag mutability setting for the repository.- Returns:
this
-
lifecyclePolicy
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder lifecyclePolicy(String lifecyclePolicy) Sets the value ofCfnRepositoryCreationTemplateProps.getLifecyclePolicy()
- Parameters:
lifecyclePolicy
- The JSON lifecycle policy text to apply to the repository. For information about lifecycle policy syntax, see https://docs.aws.amazon.com/AmazonECR/latest/userguide/LifecyclePolicies.html- Returns:
this
-
repositoryPolicy
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder repositoryPolicy(String repositoryPolicy) Sets the value ofCfnRepositoryCreationTemplateProps.getRepositoryPolicy()
- Parameters:
repositoryPolicy
- The JSON repository policy text to apply to the repository. For more information, see https://docs.aws.amazon.com/AmazonECR/latest/userguide/RepositoryPolicyExamples.html- Returns:
this
-
resourceTags
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder resourceTags(IResolvable resourceTags) Sets the value ofCfnRepositoryCreationTemplateProps.getResourceTags()
- Parameters:
resourceTags
- The tags attached to the resource.- Returns:
this
-
resourceTags
@Stability(Stable) public CfnRepositoryCreationTemplateProps.Builder resourceTags(List<? extends Object> resourceTags) Sets the value ofCfnRepositoryCreationTemplateProps.getResourceTags()
- Parameters:
resourceTags
- The tags attached to the resource.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnRepositoryCreationTemplateProps>
- Returns:
- a new instance of
CfnRepositoryCreationTemplateProps
- Throws:
NullPointerException
- if any required attribute was not provided
-