ci: version.json の commit-back を廃止しビルド時に焼き込む (backport of #136, aicshud/WHEEL#1014) - #137
Merged
so5 merged 1 commit intoSep 11, 2026
Conversation
…ime (#136) Backport of PR #136 (main) to maintenance2026. Adjusted for this branch: - kept "master" branch naming used in this line's run_test.yml / build_and_deploy.yml comments (unlike main, not yet renamed here) - kept `RUN npm prune --production` in the exec stage as-is (this branch still prunes; main's "don't prune" comment doesn't apply here) - did not add the entrypoint.sh ssh-agent block (PR #135, not backported to this branch) or the doc files that don't exist here yet (AGENTS.md, TEST_GUIDE.md, documentMD/design/{developer_guide,testing}.md) The `[skip ci] update version number` step in run_test.yml rewrote server/app/db/version.json and pushed it to every feature branch, so parallel PRs conflicted on that file and a stale `-beta` value rode onto main/maintenance at merge (issue #1014). - run_test.yml: drop the version-stamp / commit / push steps and the now-unused GITHUB_TOKEN from the test job. CI no longer touches the file. - version.json: the committed value is a fixed placeholder ("not defined - this is a development build"). Nothing in CI edits the tracked file, so it never diverges between branches -> no more conflicts. - build_and_deploy.yml: pass the computed version through the WHEEL_VERSION build-arg instead of editing the worktree; repack source.tar.gz from a clean tree with the real version dropped in (git archive shipped the placeholder before). - Dockerfile: a throwaway `versioner` stage runs `git describe` on the build context, so a plain `docker build .` still bakes a commit-identifying version (`<describe>-local`). `--build-arg WHEEL_VERSION` overrides it; an un-stamped source build keeps whatever version.json ships. No --dirty: .dockerignore hides tracked paths (documentMD/) from the stage's `COPY . .`, so --dirty would always fire. versionInfo.js is unchanged - it still statically imports version.json. (cherry picked from commit 931f0ae) Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01C3jKNM1qubomM8UTRdkEWu
so5
deleted the
backport/version-json-no-commit-back-maintenance2026
branch
September 11, 2026 13:01
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
mainの PR #136(aicshud/WHEEL#1014)をmaintenance2026へ cherry-pick したものです。内容は PR #136 と同じ —
run_test.ymlによるversion.jsonの commit-back を廃止し、ビルド時(
docker build/versionerステージ)に焼き込む方式に変更します。背景は #136 を参照してください。
このブランチ向けに調整した点
cherry-pick 時に conflict した箇所を、このブランチの実態に合わせて解消しています。
run_test.yml/build_and_deploy.ymlのコメント中のmainは、このブランチではまだ
master表記のままなのでそちらを維持しました。DockerfileのexecステージにあったRUN npm prune --productionはこのブランチ独自の既存動作なのでそのまま残し、そこにバージョン焼き込みステップを追加しました
(main 側の「pruneしない」という注釈はこのブランチには当てはまらないため入れていません)。
entrypoint.shの ssh-agent 修正(PR fix(entrypoint): start ssh-agent without writing into the bind-mounted home #135)はこのブランチにまだ backport されていないため、Dockerfile への該当ブロック追加は行っていません。
AGENTS.md/TEST_GUIDE.md/documentMD/design/developer_guide.md/documentMD/design/testing.mdはこのブランチにまだ存在しないため、対応するドキュメント修正は含めていません(
documentMD/design/design.mdは存在するので ci: version.json の commit-back を廃止しビルド時に焼き込む (aicshud/WHEEL#1014) #136 と同じ「バージョン番号の管理」セクションを追加しています)。
動作確認
このブランチの Dockerfile で実ビルドして確認しました。
docker build --target versioner:git describe(--dirtyなし)が動くこと(このブランチでは
master-14-g<sha>のような値になります)。docker build --target exec(build-arg なし):<git describe>-localがserver/app/db/version.jsonに焼き込まれること。🤖 Generated with Claude Code
https://claude.ai/code/session_01C3jKNM1qubomM8UTRdkEWu