This repository contains a DevContainer configuration for a development environment that supports both Node.js and Python. It provides a consistent, reproducible setup for developers working on projects that involve these technologies.
- Node.js LTS version
- Python 3.10
- Common development utilities
- Pre-configured VS Code settings and extensions
- Zsh with Oh My Zsh
- Neovim configuration
The DevContainer is defined by several configuration files:
-
.devcontainer/devcontainer.json
: The main configuration file that specifies:- Base image and build instructions
- Ports to forward
- Features to install (Node.js, Python, and common utilities)
- VS Code extensions and settings
- Commands to run on container creation
-
.devcontainer/Dockerfile
: Defines the custom Docker image, based on a Node.js image with added Python support. -
.devcontainer/on-create.sh
: A script that runs when the container is created, installing additional packages and configuring git. -
.devcontainer/post-create.sh
: A script that runs after the container is created, setting up Neovim configuration.
- Ensure you have Docker and VS Code with the Remote - Containers extension installed.
- Clone this repository.
- Open the repository in VS Code.
- When prompted, click "Reopen in Container" or run the "Remote-Containers: Reopen in Container" command.
- VS Code will build the Docker image and start the container. This may take a few minutes the first time.
- Once the container is running, you'll have a fully configured development environment for Node.js and Python.
You can customize the DevContainer by modifying the configuration files:
- Add or remove VS Code extensions in
devcontainer.json
- Modify container features or settings in
devcontainer.json
- Add additional software or configuration in the
Dockerfile
- Modify the setup scripts (
on-create.sh
andpost-create.sh
) to add your own initialization steps
- Consistent development environment across team members
- Easy onboarding for new developers
- Isolation from the host system
- Pre-configured tools and settings for Node.js and Python development