{"id":51451370,"url":"https://github.com/rocicorp/devcontainer-features","last_synced_at":"2026-07-05T21:01:26.212Z","repository":{"id":364028512,"uuid":"1266062993","full_name":"rocicorp/devcontainer-features","owner":"rocicorp","description":null,"archived":false,"fork":false,"pushed_at":"2026-06-25T07:07:57.000Z","size":44,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-25T09:03:46.533Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rocicorp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-06-11T09:40:49.000Z","updated_at":"2026-06-25T07:08:01.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/rocicorp/devcontainer-features","commit_stats":null,"previous_names":["rocicorp/devcontainer-features"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/rocicorp/devcontainer-features","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rocicorp%2Fdevcontainer-features","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rocicorp%2Fdevcontainer-features/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rocicorp%2Fdevcontainer-features/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rocicorp%2Fdevcontainer-features/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rocicorp","download_url":"https://codeload.github.com/rocicorp/devcontainer-features/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rocicorp%2Fdevcontainer-features/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35168795,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-05T02:00:06.290Z","response_time":100,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-07-05T21:01:25.569Z","updated_at":"2026-07-05T21:01:26.204Z","avatar_url":"https://github.com/rocicorp.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Rocicorp dev container features\n\nShared [dev container Features](https://containers.dev/implementors/features/) so every\nrepo's containers come with the same baseline — without copy-pasting `post-create.sh`\nacross repos.\n\n## `agents`\n\nInstalls the AI coding agents we standardize on:\n\n- **OpenAI Codex CLI** (`@openai/codex`, version pinned via the `codexVersion` option)\n- **Claude Code** (pulled in automatically via `dependsOn` on the official\n  `ghcr.io/anthropics/devcontainer-features/claude-code` feature)\n\n\u003e **v3.0.0** drops the bundled GitHub CLI (`gh`) and 1Password CLI (`op`), so the container no\n\u003e longer needs a GitHub token injected at shell start. If a repo still wants `gh`, add the\n\u003e official [`github-cli`](https://github.com/devcontainers/features/tree/main/src/github-cli)\n\u003e feature directly.\n\n### Persistent Claude login\n\nThe feature mounts a named volume (`devcontainer-claude-config` at `/home/node/.claude`)\nand sets `CLAUDE_CONFIG_DIR`, so the Claude session survives container **rebuilds** — you\nlog in once instead of after every rebuild. A `postCreateCommand` `chown`s the volume so\nthe `node` user can write to it.\n\n\u003e The volume is **shared across all repos** that use this feature (the Claude login is\n\u003e account-level, not repo-level), so logging in from one container carries over to the\n\u003e others. The mount path assumes the `node` remote user (the base image we standardize on).\n\n### Usage\n\nIn any repo's `.devcontainer/devcontainer.json`:\n\n```jsonc\n\"features\": {\n  \"ghcr.io/rocicorp/devcontainer-features/agents:3\": {\n    // optional — override the pinned Codex version\n    \"codexVersion\": \"0.139.0\"\n  }\n}\n```\n\nThis single line replaces the official `claude-code` feature line, the\ninline `npm install -g @openai/codex`, **and** the `.claude` volume / `CLAUDE_CONFIG_DIR` /\n`chown` wiring that otherwise lives in each repo's `devcontainer.json` + `post-create.sh`.\n\n## `pnpm`\n\nSets up [pnpm](https://pnpm.io) via [Corepack](https://github.com/nodejs/corepack):\n\n- Runs `corepack enable` (adds the `pnpm` shim) at build time.\n- At `postCreate`, runs `corepack install` to pin the pnpm version from the workspace's\n  `package.json` `packageManager` field.\n- Removes the `npm`/`npx` binaries (after build-time installs have run) to enforce\n  pnpm-only usage. This is the default; set `removeNpm: false` to keep npm available.\n\n```jsonc\n\"features\": {\n  \"ghcr.io/rocicorp/devcontainer-features/pnpm:1\": {}\n}\n```\n\nThis replaces the corepack/pnpm/npm-removal block that otherwise lives in each repo's\n`post-create.sh`. Combined with `agents`, a consumer repo's `devcontainer.json` needs no\nlifecycle scripts at all.\n\n## `docker`\n\nGives the container a working Docker daemon so tooling that shells out to Docker — most\nnotably [testcontainers](https://testcontainers.com) (used by the `zero-cache` Postgres\nintegration tests) — runs inside the dev container.\n\n- Pulls in the official\n  [`ghcr.io/devcontainers/features/docker-in-docker`](https://github.com/devcontainers/features/tree/main/src/docker-in-docker)\n  feature via `dependsOn`, which installs the Docker engine, runs a daemon **inside** the\n  container, and adds the remote user to the `docker` group (no `sudo` needed).\n- Pins `\"moby\": false` so the upstream feature installs Docker CE from Docker's own apt\n  repo instead of Microsoft's `moby-*` packages, which don't exist on Debian trixie\n  (the base of current `javascript-node` images) and fail the build.\n- Uses Docker-**in**-Docker rather than docker-outside-of-docker on purpose: testcontainers\n  relies on bind mounts and container-to-container networking, both of which break under the\n  host-socket approach (path translation) and aren't available in every environment\n  (Codespaces, CI). A self-contained daemon \"just works\" everywhere.\n\n```jsonc\n\"features\": {\n  \"ghcr.io/rocicorp/devcontainer-features/docker:1\": {}\n}\n```\n\nThis replaces a per-repo `docker-in-docker` feature line and centralizes the pinned version\nalongside the other rocicorp features.\n\n## Updating the feature versions everywhere\n\n1. Bump `codexVersion` default (and/or the `dependsOn` claude-code pin) in\n   `src/agents/devcontainer-feature.json`, raise the feature `version`, merge to `main`.\n   The release workflow publishes a new tag to `ghcr.io`.\n2. Consumer repos pick it up on next rebuild. To avoid hand-editing pins, enable\n   **Dependabot** (`devcontainers` ecosystem) in each consumer repo — it opens PRs that\n   bump the `devcontainer-lock.json` digests automatically.\n\n## Publishing\n\n`.github/workflows/release.yml` publishes all features under `src/` to\n`ghcr.io/\u003cowner\u003e/devcontainer-features/\u003cid\u003e` on push to `main`\n(via [`devcontainers/action`](https://github.com/devcontainers/action)).\n\n\u003e After the first publish, make the package public in the repo's\n\u003e **Packages** settings (or org package visibility) so consumer repos can pull it\n\u003e without auth.\n\n## Testing locally\n\n```bash\nnpm install -g @devcontainers/cli\ndevcontainer features test \\\n  --features agents \\\n  --base-image mcr.microsoft.com/devcontainers/javascript-node:24 \\\n  .\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frocicorp%2Fdevcontainer-features","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frocicorp%2Fdevcontainer-features","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frocicorp%2Fdevcontainer-features/lists"}