You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
devcontainer: bridge host known_hosts so push works under the CLI (#125)
Mirrors the existing host-gitconfig handling. Without this, git push from
inside a CLI-launched devcontainer fails with "Host key verification
failed" the first time it talks to github.com \xe2\x80\x94 the base image leaves
~/.ssh empty and SSH refuses unknown fingerprints by default.
The fix is the same shape as the gitconfig bridge:
- initialize.sh snapshots ~/.ssh/known_hosts into
.git-plumbing/host-known-hosts (empty file if absent).
- post-start.sh copies that into $HOME/.ssh/known_hosts only when the
in-container file is missing or empty, creating ~/.ssh mode 700 first.
- .gitignore covers the new runtime artifact.
- README and CLAUDE.md updated alongside.
VS Code\xe2\x80\x99s Dev Containers extension already bridges known_hosts itself, so
the empty-check naturally lets it win when it\xe2\x80\x99s involved. CI\xe2\x80\x99s
`devcontainer build` never reaches postStart, so the script is a no-op
there.
0 commit comments