Skip to content

feat: track opencode v2 releases (v2.2.4), keep v1 supported via version-v1.txt - #81

Merged
gabemeola merged 1 commit into
mainfrom
feat/track-v2-releases
Oct 30, 2026
Merged

gabemeola merged 1 commit into
mainfrom
feat/track-v2-releases

Conversation

@gabemeola

@gabemeola gabemeola commented Oct 30, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Make OpenCode v2.2.4 the default in version.txt; keep supported v1.19.5 in version-v1.txt. The scheduled checker opens independent bump PRs for both major lines.
  • Publish both pinned tracks with task publish. V2 receives its version tag, :latest, and :v2; v1 receives its version tag and :v1. Existing GitHub releases are retained.
  • Use the correct upstream installer and select the major-specific entrypoint in the Dockerfile: entrypoint.sh for v2, entrypoint-v1.sh for v1. Both share home/tool initialization.
  • Support v2's native OPENCODE_PASSWORD and legacy OPENCODE_SERVER_PASSWORD fallback. Preserve generated-password behavior when neither is set. V2 uses the fixed username opencode; v1 retains OPENCODE_SERVER_USERNAME.
  • Normalize v2 log levels to lowercase and enable its stderr logging correctly. Keep foreground serve with explicit hostname, port, and CORS flags.
  • Test the actual API routes: /api/info for v2 and /global/health for v1. Old v1 API URLs on v2 return the web app and cannot validate API authentication.
  • Run runtime CI for both versions, update the home-tool tests for v2's API, and build the size-comparison baseline using its own pinned version.

Local verification

  • Full Docker builds passed for v2.2.4 and v1.19.5 on linux/arm64.
  • Server E2E passed for both images: build-time entrypoint selection, custom port and CORS, uppercase log-level compatibility, stderr logs, real JSON API responses, missing/incorrect credentials, username behavior, and graceful shutdown.
  • V2 additionally verified OPENCODE_PASSWORD precedence, OPENCODE_SERVER_PASSWORD fallback, generated-password auth, and managed mise instructions.
  • Home-tool installation E2E passed for both images.
  • All seven bump-script tests passed; shell and workflow/Taskfile YAML checks passed; task publish dry run confirms all image tags.

One Sapling commit; no images or releases published by these checks.

Review follow-up

  • Release discovery now uses authenticated, paginated GitHub API requests, selects the highest numeric stable version per major, excludes component/prerelease/draft tags, and never downgrades the pins. The scheduled checker and task update share this implementation.
  • GitHub release creation explicitly targets the checked-out source commit. V2 is marked Latest; v1 uses --latest=false. Repository references use the canonical sprisa/opencode-server name.
  • Release notes select the highest older stable tag reachable from the current commit, including the first-v2 fallback to a lower major, while excluding future versions and unmerged tags.
  • Added eight offline release-automation integration tests and a dedicated CI job. All eight tests and the seven existing bump tests pass locally. Live upstream lookup returns v2.2.4 and v1.19.5.
  • Verified a real persistent-volume upgrade locally: create a v1 session, stop v1, start v2 on that same volume as UID 0, and retrieve the session with the same ID and title through the v2 API.
  • README links the upstream v1 migration guide for changed client and plugin APIs.

Still one Sapling commit.

Toolchain refresh and verification

  • Homebrew: 6.0.16 -> 7.0.11.
  • mise: 2026.8.3 -> 2026.10.24.
  • zerobrew: 0.3.2 -> 0.4.2; download URL uses the canonical zerobrewhq repository.
  • mise-zerobrew: 998174989a12910f82c1f6e791a432731ed2647d is already the latest upstream commit and remains pinned.
  • Fixed new mise compatibility: the scoped home-tool installer now uses an actual empty TOML config instead of /dev/null, which current mise rejects as an unknown config type.
  • Fixed readiness polling to wait through v2's temporary startup 503. Added progress messages, bounded HTTP requests, and a five-minute timeout for the package-manager E2E test.
  • Full local builds passed for all four combinations: OpenCode v1/v2 on linux/arm64 and linux/amd64.
  • Both major versions on both architectures passed server authentication/flags, delayed home-tool installation, Ruby/Wget/Nano lazy installs through the zerobrew plugin, a real Homebrew package install, and zbx execution.
  • Interactive and non-interactive Node/npm/npx/Python/GitHub CLI/Go checks also passed on arm64 and amd64. Added package-manager E2E coverage to both runtime CI jobs.

All changes remain in the single Sapling commit.

@gabemeola
gabemeola force-pushed the feat/track-v2-releases branch 4 times, most recently from 1f987f0 to ab29eb1 Compare October 30, 2026 21:18
@github-actions

github-actions Bot commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

Docker image size comparison

Image Size
Baseline (main) 989MB
This PR 1.17GB
Difference +66MB

@gabemeola
gabemeola force-pushed the feat/track-v2-releases branch 2 times, most recently from 988e1e4 to 346211b Compare October 30, 2026 21:38
…rsion-v1.txt

- version.txt pins v2 (2.2.4, published with :latest and :v2); version-v1.txt pins v1 (1.19.5, published with mutable :v1)
- release-checker: per-major matrix, one bump PR per track (upstream releases/latest is still pinned to v1, so filter the releases list by tag pattern)
- Dockerfile: use opencode.ai/v2/install for v2 versions (the v1 installer rejects v2)
- bump-version.sh: optional version-file arg
- release-notes.sh: prev tag lookup stays within the same major line
- Taskfile: task update syncs both files; task publish publishes both tracks (:latest+:v2 / :v1; skips existing GitHub Releases); docker:build:v1/docker:push:v1 for the v1 track
@gabemeola
gabemeola force-pushed the feat/track-v2-releases branch from 346211b to c225366 Compare October 30, 2026 21:58
@gabemeola
gabemeola merged commit 2f6cd10 into main Oct 30, 2026
4 checks passed
@gabemeola
gabemeola deleted the feat/track-v2-releases branch October 30, 2026 22:03
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