Amazon Elastic Container Registry (ECR) is a fully managed container image registry service that makes it easy to store, manage, and deploy Docker container images securely.
Click to reveal answer
intermediate
How does Amazon ECR help with container image security?
Amazon ECR integrates with AWS Identity and Access Management (IAM) to control who can access your container images. It also supports image scanning to detect vulnerabilities in your container images.
Click to reveal answer
intermediate
What is the benefit of using a managed container registry like ECR compared to a self-hosted registry?
Using ECR removes the need to manage infrastructure for storing container images. It provides high availability, scalability, and integrates with other AWS services, reducing operational overhead.
Click to reveal answer
beginner
What is a repository in Amazon ECR?
A repository in Amazon ECR is a collection where container images are stored and organized. Each repository can hold multiple versions of container images identified by tags.
Click to reveal answer
intermediate
How do you authenticate Docker to push or pull images from Amazon ECR?
You authenticate Docker to Amazon ECR by retrieving an authentication token using the AWS CLI and then using it to log in to the ECR registry. This token is temporary and must be refreshed regularly.
Click to reveal answer
What does Amazon ECR primarily store?
AServer logs
BVirtual machines
CDatabase backups
DContainer images
✗ Incorrect
Amazon ECR is designed to store container images used for deploying containers.
Which AWS service controls access permissions for ECR repositories?
AAWS CloudTrail
BAWS Lambda
CAWS IAM
DAWS S3
✗ Incorrect
AWS Identity and Access Management (IAM) manages permissions for accessing ECR repositories.
What is required before pushing a Docker image to ECR?
AAuthenticate Docker with ECR using a token
BCreate an EC2 instance
CEnable CloudWatch logging
DSet up a VPC
✗ Incorrect
Docker must be authenticated with ECR using a temporary token before pushing images.
Which feature helps identify security issues in container images stored in ECR?
AImage scanning
BAuto scaling
CLoad balancing
DCloudFormation
✗ Incorrect
Image scanning detects vulnerabilities in container images stored in ECR.
What is a repository in Amazon ECR?
AA database instance
BA storage location for container images
CA compute resource
DA network gateway
✗ Incorrect
A repository is where container images are stored and organized in ECR.
Explain how Amazon ECR integrates with Docker to manage container images.
Think about how Docker clients connect securely to ECR and how images are stored.
You got /3 concepts.
Describe the security features provided by Amazon ECR for container image management.
Consider both access control and image protection mechanisms.
You got /3 concepts.
Practice
(1/5)
1. What is the primary purpose of AWS Elastic Container Registry (ECR)?
easy
A. To store and manage container images securely
B. To run containerized applications
C. To monitor AWS cloud resources
D. To provide virtual machines for deployment
Solution
Step 1: Understand ECR's role
AWS ECR is designed to store container images safely and manage them.
Step 2: Differentiate from other services
Running containers is done by ECS or EKS, not ECR. Monitoring and VMs are unrelated.
Final Answer:
To store and manage container images securely -> Option A
Quick Check:
ECR = Container image storage [OK]
Hint: ECR stores images, ECS/EKS run containers [OK]
Common Mistakes:
Confusing ECR with ECS or EKS
Thinking ECR runs containers
Assuming ECR monitors resources
2. Which AWS CLI command correctly creates a new ECR repository named my-app?
easy
A. aws ecr make-repo --repository my-app
B. aws ecr new-repository --name my-app
C. aws ecr create-repository --repository-name my-app
D. aws ecr init-repository --repo my-app
Solution
Step 1: Recall AWS CLI syntax for ECR
The correct command to create a repository is aws ecr create-repository --repository-name <name>.
Step 2: Check options for correctness
Options B, C, and D use invalid commands or flags not recognized by AWS CLI.
Final Answer:
aws ecr create-repository --repository-name my-app -> Option C