Skip to content

feat(deploy): version-aware image tags — hold :latest on prereleases - #316

Merged
elliotBraem merged 4 commits into
mainfrom
feat/versioned-image-tags
Oct 9, 2026
Merged

elliotBraem merged 4 commits into
mainfrom
feat/versioned-image-tags

Conversation

@elliotBraem

@elliotBraem elliotBraem commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • bos deploy now pushes the exact v<version> tag alongside sha-<short>, and a floating v<major> tag on stable releases.
  • :latest is held while the workspace version is a prerelease - the Docker analog of the npm rc dist-tag - so deployments pulling ghcr.io/nearbuilders/everything-dev:latest keep serving the last stable image.
  • Version source is packages/everything-dev/package.json in the deploy's configDir (the source the image is built from); child repos without that workspace keep today's sha+latest behavior.

Why now

The changesets version PR (#307) bumps the workspace to 2.0.0-rc.0 with majors across the framework packages. Today the image leg only pushes sha-<sha> + latest, so merging #307 would move Docker latest to the v2 rc image immediately - npm is protected by the rc dist-tag but Docker is not. This PR should land before #307 merges.

After this PR: merging #307 pushes sha-<sha> + v2.0.0-rc.0 and leaves latest on v1. latest moves when 2.0.0 stable ships (which also starts the floating v2 tag).

Follow-up plan

I added the workflow audit and centralization plan at:

  • docs/plans/049-workflow-hardening-and-consumer-reusable-workflows.md

It captures the agreed next direction:

  • harden workflow_dispatch, deploy SHA gating, and staging parity
  • refresh CI path detection and check-skills failure handling
  • remove workflow jargon and stale wording
  • add reusable child-facing workflows named consumer-ci, consumer-deploy, and consumer-staging
  • keep child wrappers thin, local, and pinned, with a working_directory input instead of assuming a flat repo layout

Test plan

  • pnpm --filter everything-dev exec vitest run tests/unit/image-deploy.test.ts - 14 tests pass (new: prerelease hold, stable major tag, unknown-version fallback, computeImageTags units)
  • pnpm run typecheck - all workspaces pass
  • pnpm run lint - clean

Push the exact v<version> tag (and a floating v<major> on stable
releases) alongside sha-<short>. :latest is held while the workspace
version is a prerelease — the Docker analog of the npm rc dist-tag —
so deployments pulling :latest keep serving the last stable image.
Parent hardening: workflow_dispatch guarded to main/staging; deploy gated on
fresh push-triggered CI runs whose commit is still the main tip (gate job);
staging gets GHCR parity with its own image namespace (never touches
production tags); CI path gating covers bos.app.ts/bos.dev.ts/tsconfig.base.json;
check-skills fails loudly on command failure and scopes write permissions;
workflow-lint job (actionlint) guards the new reusable workflows.

Child reuse: new consumer-ci/consumer-deploy/consumer-staging reusable
workflows keyed on a working_directory input; child templates become thin
wrappers; release stays local. Jargon (train/leg/skew) removed from workflow
files and README; plan 049 records executed decisions and follow-ups.
Group the all-true GITHUB_OUTPUT writes into one redirect block (SC2129)
and disable SC2016 on the watchdog where the single-quoted $(date) is
intentional — it must expand inside the inner bash on every iteration.
@elliotBraem
elliotBraem merged commit 3e47fea into main Oct 9, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant