feat(ci/cd): Add artifact bucket and ECS deployment support

- Create S3 artifact bucket with encryption and versioning
- Add ECR lifecycle policy to maintain maximum 5 images
- Add OutputArtifacts to build stage for deployment
- Add Deploy stage with ECS provider
- Update CodePipeline artifact store to use ArtifactBucket
- Replace hardcoded bucket names with parameterized references
- Add IAM permissions for ECS task definition and service management
- Add buildspec commands to generate image definitions file
This commit is contained in:
Daisuke Nakahara 2026-01-10 19:39:15 +09:00
parent 53271302e2
commit 058d1be93f
2 changed files with 99 additions and 5 deletions

View file

@ -16,3 +16,6 @@ phases:
- set -e
- docker push ${REPOSITORY_URI}:${GIT_TAG}
- docker push ${REPOSITORY_URI}:latest
- printf '[{"name":"forgejo","imageUri":"%s"}]' $REPOSITORY_URI:$GIT_TAG > imagedefinitions.json
artifacts:
files: imagedefinitions.json