feat(installer): non-interactive credentials + softer connect copy (#834)#266
Merged
Conversation
…834) RFC-0001 Phase 0 (no backend dependency): - Accept TRACEBLOC_CLIENT_ID / TRACEBLOC_CLIENT_PASSWORD so CI / automation / golden images can provision without typing the secret inline. Verified the same way as the prompt (verify_credentials); a bad credential fails the install (no re-prompt in non-interactive mode). The interactive prompt path is unchanged — just wrapped in the else branch. - Soften the "to connect this machine you NEED a tracebloc client / create one" copy to "already have one? enter it (or set the env vars) / need one? create it" — so we stop framing client-creation as a mandatory pre-step (browser sign-in lands in Phase 1). Tests: two new bats cases (env path -> non-interactive write + helm with no prompt; rejected env creds -> error, no helm). The interactive flow tests (re-prompt / inactive / unverified / defaults / max-attempts / one-client guard) still pass unchanged. NOTE: bats #16 (_extract_yaml_value single-quote '' un-escape) fails locally on macOS bash — pre-existing and untouched by this PR (the diff doesn't go near that function); flagging for confirmation against CI. Part of backend#830. Closes #834. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
Author
|
👋 Heads-up — Code review queue is at 31 / 30 Above the WIP limit. The team convention is to review existing PRs before opening new work. Open PRs currently in Code review (oldest first):
Pull from review before opening new work. (This is a nudge from the kanban WIP check, not a block.) |
Resolve conflict in scripts/tests/install-client-helm.bats. Both develop (#262 / backend#743 — HOST_DATASET_DIR datasetPath + host uid/gid tests) and this branch (#834 — TRACEBLOC_CLIENT_* non-interactive credential tests) inserted new @test blocks at the same spot, so git interleaved them. Kept all four tests as contiguous blocks. scripts/lib/install-client-helm.sh auto-merged cleanly: #266 touches the credential-gathering block, develop touches the values.yaml heredoc (HOST_UID/GID + datasetPath) — non-overlapping. Verified the merged file is the exact union of both parents. install-client-helm.bats: 40/41 pass. The lone failure (#16 _extract_yaml_value single-quote escape) is byte-identical to develop and fails only under macOS bash 3.2.57 — pre-existing and environmental, not from this merge. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
saadqbal
approved these changes
Jun 19, 2026
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.
Summary
RFC-0001 Phase 0 (epic backend#830) — the no-backend-dependency installer quick wins. Part of
tracebloc/backend#834(partial — ships env-var credentials + softer copy; the--token/TRACEBLOC_ENROLL_TOKENenrollment token and full removal of the create-a-client step need backend work and land in a later phase).TRACEBLOC_CLIENT_ID/TRACEBLOC_CLIENT_PASSWORDso CI / automation / golden images can provision without typing the secret inline. They're verified exactly like the prompt (verify_credentials), and a bad credential fails the install (no re-prompt in non-interactive mode). The interactive prompt path is unchanged — it's just moved into theelsebranch.Why now
Phase 0 needs no backend work and removes the two sharpest onboarding pain points immediately: a secret typed into a
curl | bashprocess, and the forced detour to/clients.Test plan
bash -nclean.values.yaml, runs helm; rejected env creds → errors, no helm.#16 _extract_yaml_value: single-quoted with '' escapefails in my local run (macOS bash). The diff doesn't touch_extract_yaml_value(confirmed — 0 occurrences in the diff), so it's a pre-existing failure; flagging so it's not attributed here, and worth confirming against CI / a separate fix.🤖 Generated with Claude Code