RepositoryAutoDeleteImages

class aws_cdk.aws_ecr.mixins.RepositoryAutoDeleteImages

Bases: Mixin

ECR-specific Mixin to force-delete all images from a repository when the repository is removed from the stack or when the stack is deleted.

Sets the emptyOnDelete property on the repository.

ExampleMetadata:

infused

Example:

ecr.CfnRepository(self, "Repo").with(ecr.mixins.RepositoryAutoDeleteImages())

Methods

apply_to(construct)

Applies the mixin functionality to the target construct.

Parameters:

construct (IConstruct)

Return type:

None

supports(construct)

Determines whether this mixin can be applied to the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Static Methods

classmethod is_mixin(x)

Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.