Pipeline Optimizations
-
Initialize job - Part of new
initialize
stage - Build docker image with
--target buildenv
- Extract
node_modules
- Either
docker cp...
or volume mount - Save
node_modules
as artifact
- Either
- Build final application image and push to registry using CI_COMMIT_SHA as image tag
- Part of new
-
Remove Build Production
job -
Update dependent jobs using needs
keyword- Allow each job to run as soon as possible and not artificially delay until its stage is ready
-
Create publish job - Re-tag application container image (built in
Initialize
job) with canonical tag- DEFAULT_BRANCH -->
latest
- Version tags (e.g.,
1.0.1
) map to dashes e.g.,1-0-0
- DEFAULT_BRANCH -->
- Only run if tests/security all pass
- Push canonical tag to
ghsc/public_images
registry
- Re-tag application container image (built in
-
Ensure deployment jobs deploy canonical image tag
Edited by Martinez, Eric M.