devcontainer-helper

devcontainer-helper

Use this skill when the user asks to create, configure, update, or explain a `devcontainer.json` file or development container environment.

1Star
0Fork
更新于 1/19/2026
SKILL.md
readonly只读
name
devcontainer-helper
description

Use this skill when the user asks to create, configure, update, or explain a `devcontainer.json` file or development container environment.

DevContainer Helper

This skill assists in creating and managing devcontainer.json files for consistent development environments.

Workflow

1. specific Requirements

Before generating the file, determine the user's needs:

  • Base Environment: Do they want a pre-built image (e.g., Ubuntu, Python, Node), a custom Dockerfile, or a docker-compose.yml setup?
  • Languages & Tools: What languages (Node.js, Python, Go, Rust, etc.) and tools (Git, CLI utilities) are needed?
  • Extensions: Are there specific VS Code extensions required?
  • Ports: What ports need to be forwarded?

2. Generate Configuration

Use the template in assets/devcontainer-template.json as a starting point.

For Image-based (Simplest):
Use the image property. Add features for additional tools.

For Dockerfile:
Use build.dockerfile property pointing to their Dockerfile.

For Docker Compose:
Use dockerComposeFile and service properties.

3. Add Features

Encourage using "Features" over manual Dockerfile commands when possible for better maintainability.
Common features:

  • Node.js: ghcr.io/devcontainers/features/node:1
  • Python: ghcr.io/devcontainers/features/python:1
  • Docker-in-Docker: ghcr.io/devcontainers/features/docker-in-docker:2
  • Git: ghcr.io/devcontainers/features/git:1

4. Lifecycle Scripts

If the user needs to run commands (like npm install or pip install) after the container builds:

  • Use postCreateCommand for one-time setup.
  • Use postStartCommand for commands that run every time the container starts.

References

See references/cheatsheet.md for a list of common devcontainer.json properties and valid values.

You Might Also Like

Related Skills

create-pr

create-pr

170Kdev-devops

Creates GitHub pull requests with properly formatted titles that pass the check-pr-title CI validation. Use when creating PRs, submitting changes for review, or when the user says /pr or asks to create a pull request.

n8n-io avatarn8n-io
获取

Guide for performing Chromium version upgrades in the Electron project. Use when working on the roller/chromium/main branch to fix patch conflicts during `e sync --3`. Covers the patch application workflow, conflict resolution, analyzing upstream Chromium changes, and proper commit formatting for patch fixes.

electron avatarelectron
获取
pr-creator

pr-creator

92Kdev-devops

Use this skill when asked to create a pull request (PR). It ensures all PRs follow the repository's established templates and standards.

google-gemini avatargoogle-gemini
获取
clawdhub

clawdhub

87Kdev-devops

Use the ClawdHub CLI to search, install, update, and publish agent skills from clawdhub.com. Use when you need to fetch new skills on the fly, sync installed skills to latest or a specific version, or publish new/updated skill folders with the npm-installed clawdhub CLI.

moltbot avatarmoltbot
获取
tmux

tmux

87Kdev-devops

Remote-control tmux sessions for interactive CLIs by sending keystrokes and scraping pane output.

moltbot avatarmoltbot
获取
create-pull-request

create-pull-request

57Kdev-devops

Create a GitHub pull request following project conventions. Use when the user asks to create a PR, submit changes for review, or open a pull request. Handles commit analysis, branch management, and PR creation using the gh CLI tool.

cline avatarcline
获取