Vibe Coding DevContainer
Personal Project
Overview
A VS Code Dev Container template that reproduces a unified Python / Node.js development environment on local Macs and remote SSH servers alike. Claude Code and the Google Gemini CLI are bundled by default, so AI-assisted development (Vibe Coding) is available in the terminal the moment the container opens. Published on GitHub.
Architecture
Built on Ubuntu 24.04 (Noble). The official uv multi-stage image is used only to copy the uv binary in; Python runtime management is fully delegated to uv, leaving the system Python untouched. Node.js is downloaded from the official tarball branching on `dpkg --print-architecture` (`amd64` maps to the Node name `x64`, `arm64` stays as is), so both amd64 and arm64 are supported (verified on an arm64 Linux server).
The container runs as the non-root user `devcontainer`; `/usr/local/share/npm-global` is pre-created and owned by that user and `NPM_CONFIG_PREFIX` is set, so global `npm install` works without sudo.
`workspaceMount` is bind-mounted with `delegated` consistency, and the Node heap limit `NODE_OPTIONS=--max-old-space-size=4096` is set as a container env var.
- AI CLIs: Claude Code (official installer) and Google Gemini CLI (`@google/gemini-cli`)
- Shell: Zsh + Oh My Zsh + `zsh-syntax-highlighting` + fzf + git-delta
- Languages / tools: Node.js 24.22.1, uv 0.13.5, GitHub CLI, tmux, jq, tree, emacs-nox
- 13 VS Code extensions auto-installed (Claude Code, Gemini Companion, Cursor Pyright, Prettier / ESLint / Black, GitLens, Markdown All in One, Mermaid Chart, etc.)
- History persistence: `zsh_history` is mounted on a named volume (`devcontainer-zsh-history-<id>`) so it survives rebuilds
Host Integration & Remote Deployment
Bind-mounts the host's `~/.claude`, `~/.claude.json`, and `~/.gemini` so AI tool credentials carry over across container rebuilds. A known issue where Claude Code on macOS deletes the credentials file is documented with workarounds in `docs/known-issues.md`. `.zshrc` is committed as a shared baseline; `.gitconfig` is gitignored and generated by the bundled `sync-devcontainer.sh` from the local `~/.gitconfig`, so personal info stays out of the repo.
`scripts/sync-devcontainer.sh` rsyncs the Mac-side credential files to any remote SSH server. After a `git clone` the remote can immediately "Reopen in Container", so paired with VS Code Remote-SSH a laptop can drive a dev container on a remote SSH server.
Tool versions (`NODE_VERSION`, `UV_VERSION`, `GEMINI_CLI_VERSION`, `GIT_DELTA_VERSION`, `ZSH_IN_DOCKER_VERSION`) are externalized as build args, with defaults in two places, the Dockerfile and `devcontainer.json`. The image build clears the apt cache with `apt-get clean && rm -rf /var/lib/apt/lists/*`.