feat(tmachine): support runtime input overrides
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 68/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- rust
- 領域
- cli, release, testing-qa
調査の方向性
tmachine の install および test コマンドのエントリーポイントと、issue に記載された config.yaml の入力処理から始めます。インストーラーの入力がどのように正規化され、インストールレイヤーのハッシュに含められ、Ansible に渡されるかを追跡します。パース、優先順位、検証、キャッシュ無効化の単体テストを追加します。完了の条件は、両方のコマンドが繰り返し指定可能なオーバーライドを受け付け、Debian conformance lane が固定の :tmachine タグなしで不変の候補イメージ参照を使用することです。
索引モデルが issue の本文から書いたものです。
説明
User Story
As an integration-test author, I want to override named tmachine inputs at runtime, so that CI can test candidate artifacts using values that are known only when the workflow runs.
Problem Statement
Tmachine inputs are currently fixed in its generated YAML configuration. The install and test commands have no runtime input override, even though release-specific values such as the candidate image SHA are available to the workflow only at runtime.
The Debian conformance lane introduced in #3461 therefore loads candidate supervisor and sandbox images under the fixed :tmachine tag and writes those references into the test user's gateway configuration. This safely prevents the packaged gateway from resolving its embedded dev or release-version tag, but it hides the candidate image identity and couples the playbook to a synthetic tag.
Using the package's embedded image tag is not a safe replacement. Release Dev could refresh :dev from the registry and test an older published image, while Release Tag runs before the versioned images are published.
Impact / Why This Matters
The current fixed-tag override keeps conformance deterministic, but CI cannot express the actual candidate image tag through tmachine. That makes artifact provenance less obvious and creates a risk that a future cleanup removes the override and accidentally pulls a previously published image during release validation.
Regenerating the Nix-backed tmachine configuration for every workflow value would move runtime CI data into build-time configuration and make local reproduction unnecessarily difficult.
Proposed Design
Add a repeatable runtime --input NAME=VALUE option to the tmachine install and test commands. Runtime values should override matching configured inputs before tmachine hashes the install layer and invokes Ansible.
The resulting workflow should allow release CI to retain the candidate images' immutable source-SHA tags and invoke tmachine with an override such as:
tmachine test ubuntu-docker-rootful deb conformance \
--input openshell_runtime_image_tag="$SOURCE_SHA"
The Debian installer can then write the source-SHA image references into its minimal per-user gateway configuration. The packaged systemd unit and all other built-in gateway defaults remain unchanged.
Acceptance Criteria
-
tmachine installaccepts repeatable--input NAME=VALUEoverrides. -
tmachine testaccepts the same overrides for the installer phase. - Runtime values take precedence over matching installer inputs from
config.yaml. - Malformed overrides and unknown input names fail with actionable errors.
- Effective override values participate in the install-layer cache key.
- Existing file-path inputs continue to be canonicalized when the referenced file exists, while scalar values do not need to name an existing file.
- Unit tests cover parsing, precedence, validation, and cache invalidation.
- Release Dev and Release Tag can pass the candidate source SHA to the Debian installer and remove the fixed
:tmachineimage references. - The Debian conformance lane continues to use a local immutable candidate image and does not pull
devor release-version runtime images from the registry.
Alternatives Considered
- Keep the fixed
:tmachinealias. This is deterministic but obscures which candidate image is under test and leaves the workflow coupled to a synthetic name. - Use the image tag embedded in the packaged gateway. This can pull an older
devimage, and versioned release images are not published until after conformance succeeds. - Generate a new tmachine configuration in CI. This mixes runtime workflow values into Nix evaluation and makes equivalent local invocations harder to reproduce.
Agent Investigation
Tmachine currently stores installer and testsuite inputs as BTreeMap<String, PathBuf>. Existing paths are canonicalized before becoming Ansible extra variables; nonexistent paths are already passed through as literal values. Installer inputs are also part of the cached install-layer hash, so runtime overrides must be applied before both hashing and playbook execution.
Related to #3454 and follow-up to #3461.
- 主要言語
- Rust
- スター
- 8.7k
- フォーク
- 1.3k
- 平均マージ
- 2日 6時間
- マージ済み PR(30日)
- 301
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
NVIDIA/OpenShell のほかの issue
-
area:docs
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
-
state:triage-needed
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
-
area:cli state:validated
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
state:triage-needed
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
-
area:build spike state:review-ready state:stale
難易度 2/5 半日 初心者へのやさしさ 68/100
NVIDIA/OpenShell の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
TheLarkInn/aipm#2413 ·
-
documentation
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
alexgorbatchev/simple-ptt#15 ·
-
tooling
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
-
todo:ticket
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
taikoxyz/taiko-mono#22168 · コメント 1 件 ·