How do you give an EKS node or CI job access to ECR with least privilege?
IntermediateProductionRegistries, Tagging & Supply Chain
Answer
Pull: node role with AmazonEC2ContainerRegistryReadOnly (or scoped ecr:GetAuthorizationToken plus BatchGetImage, GetDownloadUrlForLayer on the specific repos). Push: CI role via GitHub OIDC (no static keys) with ecr:PutImage, InitiateLayerUpload, UploadLayerPart, CompleteLayerUpload, BatchCheckLayerAvailability on one repository.
More on Registries, Tagging & Supply Chain
What is a good image tagging strategy for production?BeginnerWhy is deploying by digest better than by tag?IntermediateHow do you enable immutable tags and lifecycle rules in ECR?IntermediateHow does ECR handle scanning and replication?IntermediateDocker Hub vs ECR vs GHCR vs Harbor: how do you choose?IntermediateHow do you set up a pull-through cache for Docker Hub?Intermediate