How do you design the release process so that any production artifact is traceable to a commit?
AdvancedProductionBranching and workflow design
Answer
Build once per commit, tag the image with the Git SHA, embed git describe output and SHA in the binary and as OCI labels, and promote the same digest through environments. Release notes and the deploy record link tag, PR numbers and digest. During an incident the question "what is running?" becomes a one-command answer.
docker build -t app:${GITHUB_SHA} \
--label org.opencontainers.image.revision=${GITHUB_SHA} \
--label org.opencontainers.image.source=https://github.com/org/app .
More on Branching and workflow design
How would you choose a branching strategy for a team of 40 engineers shipping a SaaS product several times a day?IntermediateWhen is GitFlow still the right choice in 2026?IntermediateHow do you support multiple released versions (1.x, 2.x, 3.x) without chaos?AdvancedHow do feature flags change your merge and release process?IntermediateWhat branch naming and commit conventions do you enforce and how?BeginnerSquash, merge commit or rebase: what do you set as the allowed method on production repos and why?Intermediate