Skip to content

Commit

Permalink
#22 Reverted ECR repo policy back to default, as an attempt to destro…
Browse files Browse the repository at this point in the history
…y a non-empty ECR repo lead to Cfn stack deletion failure, resulting in even more manual cleanup required, compared to just manually deleting the ECR repo after "cdk destroy".
  • Loading branch information
vgribok committed Nov 14, 2019
1 parent a48e73b commit 1e6b928
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion infra-as-code/CicdInfraAsCode/src/CicdInfraAsCodeStack.cs
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ private Repository CreateDockerImageRepo()
return new Repository(this, "DockerImageRepository", new RepositoryProps
{
RepositoryName = this.settings.DockerImageRepository,
RemovalPolicy = RemovalPolicy.DESTROY,
// RemovalPolicy = RemovalPolicy.DESTROY, // Destroy can only destroy empty repos. Ones with images will cause stack deletion to fail, requiring more manual cleanup.
LifecycleRules = new []
{
new LifecycleRule
Expand Down

0 comments on commit 1e6b928

Please sign in to comment.