Last active
March 26, 2023 05:47
-
-
Save li0nel/2d144623170808e642f117533bc101f4 to your computer and use it in GitHub Desktop.
CloudFormation template for ECR
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# One Docker registry that we will use both for the Laravel application | |
# image and our Nginx image. | |
# Note that if you give a name to the repository, CloudFormation can't | |
# update it without a full replacement. | |
ECR: | |
Type: AWS::ECR::Repository | |
Properties: | |
# RepositoryName: !Sub ${AWS::StackName}-nginx | |
RepositoryPolicyText: | |
Version: "2012-10-17" | |
Statement: | |
- | |
Sid: AllowPushPull | |
Effect: Allow | |
Principal: | |
AWS: | |
- !Sub arn:aws:iam::${AWS::AccountId}:role/${ECSRole} | |
Action: | |
- "ecr:GetDownloadUrlForLayer" | |
- "ecr:BatchGetImage" | |
- "ecr:BatchCheckLayerAvailability" | |
- "ecr:PutImage" | |
- "ecr:InitiateLayerUpload" | |
- "ecr:UploadLayerPart" | |
- "ecr:CompleteLayerUpload" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment