Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refine ECR repository IAM policy #13

Merged
merged 2 commits into from
Nov 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions .github/workflows/terraform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@ jobs:

- name: terraform setup
uses: hashicorp/setup-terraform@v1
with:
terraform_version: 0.12.29
# cli_config_credentials_token: ${{ secrets.TF_API_TOKEN }}

# TODO: This step duplicates work done by the Makefile.
# - name: check terraform formatting
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ The following arguments are supported:

* `lifecycle_policy_path` – (Optional) Path to JSON document containing lifecycle policy.

* `readers` - (Optional) List of account ARNs that can pull images.
* `readers` - (Optional) List of account ARNs that can pull images. These accounts are also granted describe and list access to the corresponding repo(s) and images.

* `repos` - (Required) List of repository names.

Expand Down
3 changes: 3 additions & 0 deletions policy.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ locals {
actions_read = [
"ecr:BatchCheckLayerAvailability",
"ecr:BatchGetImage",
"ecr:DescribeImages",
"ecr:DescribeRepositories",
"ecr:GetDownloadUrlForLayer",
"ecr:ListImages",
]
actions_write = [
"ecr:BatchCheckLayerAvailability",
Expand Down
2 changes: 1 addition & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ variable "lifecycle_policy_path" {
}

variable "readers" {
description = "List of account ARNs that can pull images."
description = "List of account ARNs that can pull images. These accounts are also granted describe and list access to the corresponding repo(s) and images."
type = list(string)
default = []
}
Expand Down
2 changes: 1 addition & 1 deletion versions.tf
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
terraform {
required_version = ">= 0.12"
required_version = ">= 1.3"
}
Loading