fix(release): promote exact beta image manifests - #925
Conversation
|
@miravoss26 could you review this stacked draft? It binds stable to the exact Core and updater beta digests and closes the rerun, partial-state, migration, and runtime-identity gaps found in two independent passes. GitHub checks do not run while the PR targets the Dependabot branch because the workflows filter pull requests to @codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 30af2e9206
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
30af2e9 to
3f397e7
Compare
|
Both review findings are fixed on exact head @codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 3f397e7d19
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| candidateBase, beta := releaseVersionBase(candidate) | ||
| if !beta || candidateBase != baked || candidate == candidateBase || imageTag != candidate { | ||
| return baked, false |
There was a problem hiding this comment.
Preserve the beta identity across automatic rollback
When a site running vX.Y.Z-beta.N updates to a later beta and the new Core fails its health check, restorePreviousComponentImage retags the prior image as ftw-rollback-* and passes that synthetic value as FTW_IMAGE_TAG (go/cmd/ftw-updater/main.go:722-734). This exact-match check rejects that tag and reports the baked stable vX.Y.Z instead of the restored candidate; because the version comparator ranks the stable version above every same-base beta, the beta checker then stops offering the failed candidate for retry. Preserve the prior exact deployed tag during rollback, or otherwise recover the build-bound candidate identity.
Useful? React with 👍 / 👎.
| imageTag := os.Getenv("FTW_IMAGE_TAG") | ||
| builtVersion := Version | ||
| resolvedVersion, imageTagApplied := runtimeVersionFromImageTag(builtVersion, CandidateTag, imageTag) | ||
| Version = resolvedVersion |
There was a problem hiding this comment.
Pass the image tag through legacy compatibility overrides
On the explicitly supported older/developer Compose layouts with a hard-coded Core image, prepareComponentImagePin generates a transient override containing only the replacement image field (go/cmd/ftw-updater/main.go:772-780). Exporting FTW_IMAGE_TAG to the Compose process selects that image but does not place the variable inside the container unless the service has an environment mapping, so a beta update on such a layout reaches these lines with an empty tag and identifies itself as the baked stable release. Add the environment mapping to the transient compatibility override so status, update checks, and fleet reporting retain the beta identity.
Useful? React with 👍 / 👎.
Summary
Why
The current stable job rebuilds the containers from the same Git commit. That does not reproduce the tested bytes: the binary embeds its version, and base images and OS packages can move between builds. A direct retag of today's beta is also wrong because the binary and OCI labels still identify that beta.
This change gives beta one build-bound candidate tag while baking the future stable product version. The beta prerelease stores
ftw-image-digests.json. Stable createsftw-promotion-receipt.jsonbefore it writes any alias, then copies onlysource@recorded_digestfor Core and updater. Every later rerun must use the same receipt.Rerun and partial-state rules
latestRuntime identity
The Core binary accepts only its baked stable version or the exact beta tag bound at build time. The updater passes the immutable deployed tag through Compose and persists it in
.env. Linux, macOS, the modular-stack helper and both legacy migration paths carry the same value.Verification
make verifyactionlintfor beta, release and release-assets workflowsStack and merge order
This draft is based on the exact head of #876 because that PR has right of way in the three release workflow files. Merge or rebase #876 first, then retarget this PR to
masterand rerun the same checks. Draft #735 still ownstest.yml; this stack does not change that file, and #735's owner has been asked to confirm #876's order.#728 is not a dependency. No existing beta can be promoted with this contract; publish a new beta after this lands.