AWS::ECR::Repository LifecyclePolicy - Amazon CloudFormation
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

AWS::ECR::Repository LifecyclePolicy

The LifecyclePolicy property type specifies a lifecycle policy. For information about lifecycle policy syntax, see Lifecycle policy template in the Amazon ECR User Guide.


To declare this entity in your Amazon CloudFormation template, use the following syntax:


{ "LifecyclePolicyText" : String, "RegistryId" : String }


LifecyclePolicyText: String RegistryId: String



The JSON repository policy text to apply to the repository.

Required: No

Type: String

Minimum: 100

Maximum: 30720

Update requires: No interruption


The Amazon account ID associated with the registry that contains the repository. If you do
 not specify a registry, the default registry is assumed.

Required: No

Type: String

Pattern: ^[0-9]{12}$

Minimum: 12

Maximum: 12

Update requires: No interruption

See also