| created | 2026-09-28 |
|---|---|
| updated | 2026-11-24 |
| last_updated_session | authoring-run/90c31b49-3d89-43f7-922e-ba48b6f34371 |
The standalone Release OCC CLI workflow and Release OCE call the same jobs to build and verify four versioned OCC binaries. These jobs publish those bytes and a checksum file to GitHub Releases.
.github/workflows/cli-release.yml:jobs.prepare: manual dispatch onmainwith the exact workflow source SHA and successful main-push CI run ID..github/workflows/cli-release-prepare.yml:jobs.preparebuilds the artifacts..github/workflows/cli-release-publish.yml:jobs.publishpublishes them.
graph TD
A["Select source on main"] --> B["Validate source and OCE version"]
B --> C["Build four versioned Go binaries"]
C --> D["Check platform metadata, native command and SHA-256"]
D --> E["Retain exact assets in the workflow run"]
E --> F["Revalidate release evidence and protected environment"]
F --> G["Create or verify source tag and draft release"]
G --> H["Upload missing assets and compare downloads"]
H --> I["Publish the verified draft"]
scripts/ci/cli-release.ts:validate checks the root package version against the
chart version and appVersion. The standalone workflow requires a successful
push CI run and CI Required for its own workflow commit on main. Release OCE
builds the CLI from its reviewed source commit and requires the approved full
suite for that source before publication.
scripts/ci/cli-release.ts:packageCli resolves its output directory to an absolute
path, including when the caller supplies .. Native verification executes that
file without searching PATH. It builds with CGO_ENABLED=0 for Darwin
and Linux on amd64 and arm64 using pinned Go 1.27.3. The build embeds
v<version> in the CLI, checks the source commit and Go platform metadata,
runs --version and --help on the runner-native
binary, and writes SHA256SUMS. The prepare job has read-only repository
permission and retains its output as one workflow artifact. The publication
job consumes that artifact without rebuilding it.
The prepare job records the artifact name and the SHA-256 of SHA256SUMS.
The publisher uses the checksum file to verify each original binary. A
standalone failed-job rerun can use the retained build artifact.
scripts/ci/cli-release.ts:publish rechecks the release source, the protected
container-publish environment, and each local checksum. It creates a
lightweight version tag only when none exists; a matching tag is required on a
retry. It finds an existing draft through the authenticated release list,
creates one if absent, and uploads only missing assets,
downloads every asset, and compares each byte with the prepared artifact before
publishing the draft. Release OCE verifies all five public downloads without
credentials before the image aliases can move. A recovery can continue from an
already published release only when the source and bytes match.
A failed run can leave a tag without a release, a tag with a draft, or an
already published release.
This assumes trusted release administrators do not change the tag or draft during publication. The workflow concurrency group serializes participating jobs but cannot exclude independent GitHub writers. A competing write between the asset checks and draft publication could invalidate their binding. Users download binaries from the published release.
- Run
node --test tests/integration/cli-release.test.tswith a writable Go cache to build all four binaries, run the native command, and reject a changed binary. The retry uses current-directory output in a disposable source fixture. This does not publish to GitHub. - Check the selected workflow run's source SHA, prepare artifact, tag target,
release assets, and
SHA256SUMS. A draft means publication stopped before the user-facing release became available. - A tag pointing to another source, changed existing asset, or already published standalone release stops a standalone retry. Before retrying, check the tag target and the authenticated GitHub release list. Do not move an established release tag.
[keep this for the user to add notes. do not change between edits]
-
2026-11-24 13:12: Distinguish CLI source qualification for standalone and combined releases. (authoring-run/90c31b49-3d89-43f7-922e-ba48b6f34371 - 165ced7e4797491e18768dafac4a76b369a025cb)
-
2026-11-24 11:32: Trace shared CLI jobs and public asset verification. (authoring-run/90c31b49-3d89-43f7-922e-ba48b6f34371 - 6908216b29038bd850b44f084b07ba7f886614d5)
-
2026-11-22 23:03: Corrected CLI publication failure states and retry checks (authoring-run/167f564b-fc8b-423a-bc84-6424a8db549d - 428f5fedbb16ec1be835dee171fc6b0b824af9b3)
-
2026-10-24 21:35: Retained current-directory packaging and Go 1.27.3 during the main-branch sync (merge-readiness-20261025T022847Z - c27fb27edfa1fdcb3417494f2bac8814d0631a63)
-
2026-10-24 13:47: Documented absolute packaging paths and current-directory retry verification (authoring-run/13963312-37cc-41b3-9ddb-00da20e78c92 - 7f39fb17418ed8653f1dfb71b0204a65f636aa7e)
-
2026-10-23 15:28: Require Go 1.27.3 for the existing clean-source CLI packaging gate (authoring-run/9b2870c6-312f-48b7-a654-186ae5ec4668 - 5370e972f8b1d51222d79b64c375e8e13a2bd452)
-
2026-09-28 17:25: Clarified draft lookup and failed-job artifact reuse (authoring-run/185ec4e3-7292-41e3-a669-f574bccc3b16 - fd9ed7f3f50c8e1f9867acb55b2b7bce00c341fa)
-
2026-09-28 15:34: Documented the CLI release build, gate and draft publication path (authoring-run/9245ac4f-d350-4d1e-920b-3d9d638de966 - 7cd4a210d8cf63e6b541427c7d46d7524736a8dc)