HUB
Sign inSign up
github-ssh logo

sbx/github-ssh

Verified Publisher

By Docker, Inc

•Updated about 1 hour ago

Pre-populates GitHub host keys so SSH operations work without interactive host verification prompts.

Sandbox Kit
0

10K+

sbx/github-ssh repository overview

Digest

sha256:0f427f631f8f…

Size

4.2 kB

Schema

v3

Pushed

about 1 hour ago

Specificationspec.yaml

MIXIN

Pre-populates GitHub host keys so SSH operations work without interactive host verification prompts.


Arguments
NameRequiredDefaultDescription
versionRequired—

Kit revision supplied by the DHI build


Providesgithub-ssh

CapabilitiesExpand a row to see its full configuration. See the full spec for the complete descriptor.
TypeRequiredDescription
com.docker.sandbox/ssh-agent@1Required—
com.docker.sandbox/network-policy@1Required—
com.docker.sandbox/lifecycle@1Required—
com.docker.sandbox/agent-context@1Optional—
com.docker.sandbox/agent-context@2Optional—

Requiresdeb/openssh-client

Apply this mixin to a sandbox

sbx run <agent> --kit sbx/github-ssh:latest

Make sure you have docker sbx installed

Run the following command to install sbx on your machine.

macOS
brew install docker/tap/sbx
Windows
winget install Docker.sbx
Learn more about docker sbx⁠

⁠GitHub SSH

This v3 mixin Kit pre-populates ~/.ssh/known_hosts with GitHub's host keys so SSH operations to GitHub work without interactive host verification prompts. It composes with a compatible workload.

This Kit is built on Docker Hardened Images.

Without this kit, SSH connections from a sandbox to GitHub fail because there is no TTY available to interactively accept a new host key.

⁠Prerequisites

Your SSH key must be loaded in the agent on the host and registered with your GitHub account. Start the sandbox with this kit attached, from its published OCI artifact on Docker Hub:

sbx run sbx/claude --kit sbx/github-ssh

⁠Usage

Once the kit is installed, SSH operations to GitHub work without any additional configuration:

git clone [email protected]:org/repo.git
git push origin my-branch

⁠Composing with git-ssh-sign

If you also want SSH commit signing, combine this kit with git-ssh-sign⁠:

sbx run sbx/claude --kit sbx/github-ssh --kit sbx/git-ssh-sign

⁠How it works

When the kit is built, it fetches GitHub's SSH host keys from https://api.github.com/meta⁠ (the canonical source GitHub publishes) and ships them in the image at /usr/share/github-ssh/known_hosts. At install time, the kit appends them to /home/agent/.ssh/known_hosts. Creating a sandbox makes no call to GitHub, so GitHub's rate limit on anonymous API calls cannot block or delay it. When GitHub rotates a host key, a tracker on the same endpoint opens a pull request that rebuilds the kit with the new key. Until the rebuilt kit is published, it still ships the old key, and SSH to GitHub from new sandboxes can fail host key verification for the rotated key type.

⁠Requirements and scope

The workload must provide deb/openssh-client in addition to the v3 platform floor. Node is not required. The runtime agent grant is restricted to Git authentication as [email protected]; it permits neither Git signing nor logins elsewhere. When the workload itself asks for the unrestricted agent, as sbx/claude and sbx/codex do, the composed runtime grant is unrestricted, because the widest grant wins. The private key stays outside the sandbox.

There are no CREATE-time arguments. Host-key setup retains existing entries, adds only missing keys, and fails when the shipped keys are missing. For install-time SSH cloning, combine with github-clone⁠, which separately requests an optional install-phase GitHub agent binding. This kit's own agent grant remains runtime-only.

See the Sandbox Kit v3 specification⁠ for the Kit format and capability contracts.