Skip to content

Improve devcontainer configuration#23

Merged
key merged 5 commits intomainfrom
chore/improve-devcontainer-config
Feb 11, 2026
Merged

Improve devcontainer configuration#23
key merged 5 commits intomainfrom
chore/improve-devcontainer-config

Conversation

@key
Copy link
Member

@key key commented Feb 10, 2026

Summary

  • Add env-file support for cleaner environment variable management
  • Switch to shared Claude and gh config volume mounts
  • Add permission fixes for .config and .claude directories
  • Auto-skip Claude Code onboarding for smoother developer experience

Test plan

  • Rebuild devcontainer and verify it starts successfully
  • Verify Claude Code works without onboarding prompts
  • Verify gh CLI has persistent config

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores
    • Dev container now supports loading an env file and uses updated volume mounts for improved local setup.
    • Removed a container-level secret mapping to avoid exposing a token at runtime.
    • Added an example env file to guide local configuration.
    • Initialization script sets ownership on config directories and auto-creates a completed-onboarding file to streamline first-run setup.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@coderabbitai
Copy link

coderabbitai bot commented Feb 10, 2026

Caution

Review failed

The pull request is closed.

Walkthrough

Updated the devcontainer to load env vars from .devcontainer/.env, adjust volume mounts (rename Claude volume and add GitHub CLI volume), remove a container-level CLAUDE token mapping, add an .env.example, and extend the post-create script to fix ownership and auto-create .claude.json onboarding data when absent.

Changes

Cohort / File(s) Summary
Devcontainer manifest
.devcontainer/devcontainer.json
Added --env-file .devcontainer/.env to runArgs; replaced volume sigrok-mcp-server-claude-settings with claude; added source=gh,target=/home/vscode/.config/gh,type=volume; removed CLAUDE_CODE_OAUTH_TOKEN from containerEnv.
Post-create script
.devcontainer/post-create.sh
Added chown -R vscode:vscode for /home/vscode/.config and /home/vscode/.claude; create $HOME/.claude.json with onboarding flags/timestamp when missing.
Env example & CI
.devcontainer/.env.example, .github/workflows/devcontainer.yml
Added .env.example template and changed CI step to copy it to .devcontainer/.env (replaced former directory/file creation step).

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 I hopped through dots and container seams,
I tucked an env file into devcontainer dreams,
Claudes and GH volumes set to share,
Chown made comfy, onboarding placed with care,
A little rabbit cheers — all set and fair! 🥕

Tip

Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord.


Note

🎁 Summarized by CodeRabbit Free

Your organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login.

Comment @coderabbitai help to get the list of available commands and usage tips.

key and others added 4 commits February 10, 2026 11:56
Add sudo to chown commands in post-create.sh to fix permission errors
when volume-mounted directories are owned by root. Add .env.example
template for environment variable configuration.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The devcontainer.json specifies --env-file .devcontainer/.env in runArgs,
but .env is gitignored and does not exist in CI. This caused docker run
to fail with "no such file or directory". Copy .env.example to .env
before the build step to provide the required (empty) env file.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The host-side ~/.claude directory is not used by the devcontainer,
which mounts a Docker volume at /home/vscode/.claude instead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@key key merged commit fddce2f into main Feb 11, 2026
5 checks passed
@key key deleted the chore/improve-devcontainer-config branch February 11, 2026 02:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant