docs: Add FAQ section and update CLI Reference in README - #39
Conversation
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add a 7-entry FAQ section covering common customization tasks (runtime versions, custom tools, firewall domains, API keys, stack changes, file preservation semantics, and VS Code extensions). Add `agentbox update` subsection and `--runtime-version` flag to CLI Reference. FAQ entries for devcontainer.json edits include a version-control/git-diff workaround for the overwrite-on-update behavior. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…pr in-progress) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Codex Code ReviewThe changes are limited to README documentation, and the new CLI reference and FAQ entries appear consistent with the current command flags and update behavior in the codebase. I did not find any discrete documentation errors in the diff that would mislead users into unsupported workflows. Automated review by Codex Review Agent |
BjRo
left a comment
There was a problem hiding this comment.
Go Code Review
Summary
Documentation-only PR adding a FAQ section (7 entries) and CLI Reference updates to README.md. I verified every FAQ claim against the actual codebase (cmd/init.go, cmd/update.go, internal/firewall/merge.go, internal/dockerfile/split.go, internal/config/config.go, and all relevant templates). All documentation claims are factually accurate.
Verified claims:
mise-config.tomlpreservation on update (update.go lines 98-125)- Custom stage preservation via
SplitAtCustomStage(update.go line 86) --runtime-versionflag exists oninitonly, withtool=versionformat (init.go lines 180-181, 328-343)- User extra domains classified as Dynamic (merge.go lines 73-89)
devcontainer.jsonregeneration on update (renderFiles output, no preservation logic)--stackon update reads from.agentbox.ymlwhen omitted (update.go lines 51-65)--extra-domainson update reads from.agentbox.ymlwhen omitted (update.go lines 67-74)--forceflag behavior (update.go lines 88-96)- All files listed in the "safe to edit" table match the renderFiles output map (init.go lines 312-324)
- Generated
devcontainer.jsonhas onlyOPENAI_API_KEYin containerEnv (devcontainer.json.tmpl line 27) - Default extensions are
anthropic.claude-codeandopenai.chatgpt(devcontainer.json.tmpl lines 9-10)
One observation worth noting: the --stack flag description in the agentbox update CLI Reference table says "Reuses recorded stacks if omitted" which correctly describes the code behavior. However, the cobra help text in cmd/update.go:169 says "Auto-detects if omitted" which is misleading -- the code reads from .agentbox.yml, it does not auto-detect. The README documentation is more accurate than the cobra help text itself. Consider fixing the cobra description in a follow-up.
Markdown formatting is consistent with the rest of the document: level-2 heading for the FAQ section, level-3 for each question, fenced code blocks with language tags, consistent table formatting.
Verdict
LGTM -- all documentation claims verified against source code, Markdown formatting is consistent, and the FAQ entries provide practical, accurate guidance.
Automated review by Go Review Agent
| @@ -199,6 +211,106 @@ | |||
There was a problem hiding this comment.
SUGGESTION: The README correctly says "Reuses recorded stacks if omitted" here, which matches the actual code at cmd/update.go lines 51-65 (reads from .agentbox.yml). However, the cobra help string at cmd/update.go:169 says "Auto-detects if omitted" which is inaccurate -- update does not auto-detect, it reads from the config file. Consider a follow-up to fix the cobra description to match this (correct) README text.
| | `mise-config.toml` | **Preserved** -- your version pins are never overwritten | | ||
| | `Dockerfile` (agentbox stage) | Regenerated | | ||
| | `devcontainer.json` | Regenerated | | ||
| | `init-firewall.sh`, `warmup-dns.sh` | Regenerated | |
There was a problem hiding this comment.
SUGGESTION: The FAQ correctly warns that devcontainer.json is regenerated on update and suggests using git diff to restore changes. A possible improvement for a future PR: support a containerEnv override mechanism (e.g., reading extra env vars from .agentbox.yml) so users do not lose custom API key forwarding on every update. This is not a documentation issue -- the guidance here is accurate and practical.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The cobra help string said "Auto-detects if omitted" but the update command actually reads stacks from .agentbox.yml when the flag is omitted. Updated to match the actual behavior. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Rework: Addressing review findings
|
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
BjRo
left a comment
There was a problem hiding this comment.
Go Code Review (Iteration 2)
Summary
Reviewed the rework addressing two SUGGESTION-level findings from iteration 1.
Finding 1 (Cobra help text): Correctly fixed. The --stack flag help in cmd/update.go line 169 now reads "Reuses stacks from .agentbox.yml if omitted" which accurately reflects the fallback behavior at lines 61-65 where agentboxCfg.Stacks is used when no --stack flag is provided. Verified by building the binary and checking agentbox update --help.
Finding 2 (containerEnv override): Acknowledged as a future feature request, no code change expected. The FAQ entries for API keys and VS Code extensions now include a practical git diff workaround for the overwrite-on-update limitation.
New content review:
- The
agentbox updateCLI reference table is accurate -- all four flags (--stack,--extra-domains,--dir,--force) match their definitions incmd/update.golines 169-172. - The
--runtime-versionaddition to theagentbox inittable matchescmd/init.golines 180-181. - All seven FAQ entries are factually correct against the codebase. Preservation semantics for
mise-config.tomland the Dockerfile custom stage are accurately described. - No new issues introduced by the rework.
- All tests pass.
Verdict
LGTM -- no remaining findings.
Automated review by Go Review Agent
Codex Code Review (Iteration 2)The patch mainly updates documentation, but one new FAQ entry describes a CLI workflow that does not work in the default interactive
Automated review by Codex Review Agent |
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
In interactive mode, the wizard overrides the --extra-domains flag with its own prompt values. Update the FAQ example to include -y and add an explanatory note so users are not misled into thinking the flag works without non-interactive mode. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Codex Code Review (Iteration 3 - Final)The changes are limited to documentation and a help-string clarification, and they are consistent with the current command behavior shown in
|
BjRo
left a comment
There was a problem hiding this comment.
Go Code Review (Iteration 3)
Summary
This PR adds a well-structured FAQ section to the README and fills a gap in the CLI Reference by documenting agentbox update and the --runtime-version flag on agentbox init. It also fixes the Cobra help text for the --stack flag on update (previously said "Auto-detects if omitted" when the command actually reuses stacks from .agentbox.yml).
All findings from iterations 1 and 2 have been addressed correctly:
-
Cobra help text bug (iteration 1):
cmd/update.goline 169 now reads"Reuses stacks from .agentbox.yml if omitted."-- matches the actual behavior at lines 61-65 where stacks are read fromagentboxCfg.Stacks. -
containerEnv override acknowledgement (iteration 1): FAQ entries for API keys and VS Code extensions now include a
git diffworkaround suggestion for the regeneration trade-off. -
Missing
-yflag in FAQ example (iteration 2): The--extra-domainsexample now showsagentbox init -y --extra-domains ...with an explanatory paragraph about why-yis required (the wizard overrides the flag in interactive mode). Verified againstcmd/init.golines 81-97 -- the wizard'schoices.ExtraDomainsdoes override the flag value.
Verification of documentation accuracy:
- CLI Reference table for
agentbox initmatches all 5 flag definitions incmd/init.golines 176-181. - CLI Reference table for
agentbox updatematches all 4 flag definitions incmd/update.golines 169-172. - FAQ "What's safe to edit" table matches the actual update behavior:
mise-config.tomlpreserved (line 122-124), custom stage preserved (line 109-111), everything else regenerated viarenderFiles. - Tests pass, linter clean, no code changes beyond the help text fix.
Verdict
LGTM -- no findings. All previous rework verified and correct.
Automated review by Go Review Agent
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Summary
## FAQsection to README.md with 7 practical entries covering common customization tasks (runtime versions, custom tools, firewall domains, API keys, stack updates, file preservation, VS Code extensions)### agentbox updatesubsection and--runtime-versionflag foragentbox initTest plan
go test ./...passes (no Go code modified)golangci-lint run ./...passesBean:
agentbox-tghq🤖 Generated with Claude Code