| Provider | Integration | Auth |
|---|---|---|
| GitHub | CodeStar Connections | OAuth, PAT |
| GitLab | CodeStar Connections | OAuth |
| Bitbucket | CodeStar Connections | OAuth |
| CodeCommit | Native (deprecated for new users) | IAM, SSH, HTTPS |
AWS CodeCommit không còn nhận new customers (July 2024). AWS khuyến nghị dùng third-party Git providers với CodeStar Connections.
GitHub/GitLab/Bitbucket → CodeStar Connection → CodePipeline
# Login to ECR
aws ecr get-login-password --region us-east-1 | \
docker login --username AWS --password-stdin 123456789012.dkr.ecr.us-east-1.amazonaws.com
# Build, tag, push
docker build -t my-app .
docker tag my-app:latest 123456789012.dkr.ecr.us-east-1.amazonaws.com/my-app:latest
docker push 123456789012.dkr.ecr.us-east-1.amazonaws.com/my-app:latest
| Feature | ECR Public | ECR Private |
|---|---|---|
| Access | Anyone | IAM-controlled |
| Scanning | Basic | Basic + Enhanced (Inspector) |
| Lifecycle | ✅ | ✅ |
| Cross-account | ❌ | ✅ (resource policy) |
Exam Tip: CodeStar Connections cho GitHub/GitLab integration. ECR cho container images. S3 as source cần versioning enabled.