Repository navigation
docs: show how to run sessions in an image on another base - #610
Merged
kalaspuff merged 3 commits intoNov 20, 2026
Merged
Conversation
Sandbox images gets a section, An image from another base, with a Dockerfile that makes Ubuntu 24.04 into an image sessions run in: fctl from its installer, Claude Code as the user, git, gh and bash. It says that fctl-agent needs no installing, since the host copies its own in, which of the image's variables reach Claude, that the image's entrypoint doesn't run, and how to keep the image current. What an image needs now lists everything the host and fctl-agent use.
…e-documented-in-our-docs-and # Conflicts: # docs/README.md
This comment has been minimized.
This comment has been minimized.
The check command passes --entrypoint sh, since docker run would otherwise hand sh -s to the image's ENTRYPOINT, which sessions never run. The host also runs cat in sandboxes (Firecracker's fctl-agent install, and containers where it doesn't run as root). And the session's log names only some of the fctl commands an older fctl lacks: say which.
kalaspuff
approved these changes
Nov 20, 2026
kalaspuff
deleted the
fctl/1526-it-should-be-documented-in-our-docs-and
branch
November 20, 2026 14:36
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
Sandbox images now has a section, An image from another base, for people who want their sessions in an image of their own that doesn't start from
ghcr.io/hyperstructure/sandbox, such as an Ubuntu image with their company's toolchains. It gives a Dockerfile that makes Ubuntu 24.04 into such an image: fctl from its installer, Claude Code as the user, git, gh, bash, sudo and/var/cache/fctl. It explains that fctl-agent needs no installing, since the host copies its own (of the host's version) into each sandbox when a session starts. The rest is what people trip on: Claude gets only the image's PATH, locale, TZ and TMPDIR, so other variables go in the project's environment. Debian's and Alpine's login shells reset the PATH for setup scripts. The image'sENTRYPOINTandCMDdon't run. Docker's cache keeps an old fctl and Claude Code until the image is rebuilt. Another distribution, Alpine, takes the same steps.What an image needs now lists everything the host and fctl-agent actually use (the system commands the host runs by path, bash for setup scripts, CA certificates, a
/etc/passwdline for the user), and the dev container paragraph and llms.txt point to the new section. The Dockerfile is the one hyperstructure/sandbox keeps and checks for both architectures in its Examples workflow. I built it with buildah on arm64 (no Docker in the session) and ran that repository's newexamples/check.shin it and in an Alpine variant. I also started fctl-agent in the built image as the host does, andcargo test -p xtask docspasses.Worth confirming
Decision: The .NET example now says that
DOTNET_ROOTandDOTNET_CLI_TELEMETRY_OPTOUTalso go in the project's variables for Claude's commands. fctl-agent passes Claude only an allowlist of the image's variables (crates/fctl-agent/src/claude.rs), so itsENVlines never reached Claude.Assumption: Recommending the latest fctl in the image (or a pinned
FCTL_VERSION) is fine even when hosts run an older version. I didn't check how an older fctl-agent answers a newer fctl's calls.Assumption: No session ran end to end in the example image: the session had no Docker. The checks cover each thing the host and fctl-agent do in a sandbox, separately.
docs: show how to run fctl sessions in an image on another base sandbox#16
fctl session
Note
Low risk. Documentation only: no code changes, though it points at example files in the sandbox repository that must exist on its main branch.
What it does. Adds a guide to docs/sandbox-images.md for building a session image on another base such as Ubuntu or Alpine, with what fctl needs in it, a check script to run against the image, and how to keep it current. The README and llms.txt index entries are updated to match.
Depends on sandbox#16. The links to
examples/ubuntu/Dockerfileandexamples/check.sh, and thecurlofcheck.sh, work only once hyperstructure/sandbox#16 is merged.fctl review's first look at
dcd8e39· 3 files, +166 −20 · Review agent settings