AWS · Containers

Amazon ECR

A managed container image registry with vulnerability scanning, lifecycle rules and replication across Regions and accounts.

On the SAA-C03 exam listAutomation

What it is and what problem it solves

Amazon Elastic Container Registry (ECR) stores container images and other OCI artefacts (such as Helm charts) in private repositories controlled by IAM, and in a public registry (ECR Public). It integrates with ECS, EKS, Lambda container images and CI/CD pipelines, can scan images for vulnerabilities (with Amazon Inspector for enhanced scanning), replicate images to other Regions and accounts, and delete old images with lifecycle policies.

When to use it

  • Any container workload on AWS that needs a private registry close to where it runs.
  • You want vulnerability scanning on push and continuous rescanning.
  • Images must be available in several Regions or accounts.

When to avoid it

  • You already standardise on another registry and cross-cloud portability matters more than integration.
  • Storing arbitrary files: use S3.

Limits and quotas

ItemValueContextSource
Images per repository 100,000
Can be raised with a quota request
Source
checked
Repositories per Region 100,000
Can be raised with a quota request
Source
checked
Maximum layer size 52,000 MiB
Fixed limit
Source
checked
Rules per lifecycle policy 50
Fixed limit
Source
checked

Quotas and limits change. Check the linked source before designing around a number.

Cost model

What you pay for

Storage per GB per month (private and public), and data transfer to the internet. Transfer to EC2, Fargate and Lambda in the same Region is free; enhanced scanning is billed by Inspector.

Where it is cost-efficient

Images pulled by workloads in the same Region.

Where costs grow

Thousands of old image versions kept forever, and pulls across Regions or to the internet.

Cost controls and common surprises

Lifecycle policies to expire untagged and old images, replication only where needed, and pull-through cache rules for public images.

Prices differ by Region and change over time; see the pricing page linked under Sources.

Security

Controls the service provides

Encryption at rest (AES-256 or KMS), IAM and repository policies, image tag immutability, basic and enhanced scanning.

What you configure

Turn on tag immutability, scan on push, restrict who can push, and use VPC endpoints for private pulls.

Logging and monitoring

CloudTrail for API calls; scan findings to EventBridge and Security Hub.

Related security services

Inspector, KMS, IAM, VPC endpoints.

Shared responsibility

AWS runs the registry. You control access, images and their contents.

Common service combinations

CodeBuild or other CI pushing images, ECS and EKS pulling them, Inspector scanning, cross-Region replication for DR.

Business application examples

  • Every build pushes an immutable tag, scanned on push, and old images expire after 90 days.

Exam cues and common confusions

  • Private container registry on AWS: ECR.
  • Scan images for CVEs: ECR scanning (enhanced with Inspector).
  • Images in another Region: ECR replication.

Related

Courses and lessons

Services, comparisons and patterns

Sources

Independent study material, not affiliated with or endorsed by Amazon Web Services. AWS and service names are trademarks of Amazon.com, Inc. or its affiliates.

Last reviewed · By the ByteCamel team · How we write content

Was this page helpful?

Report a mistake