Launch disposable VS Code development environments for YOLO mode development with AI tools like Claude Code and Gemini. Either locally with Docker or remotely on Fly.io (AWS, GCE, Digital Ocean coming soon). Like Code Spaces, but fully self hosted and open source.
- π³ Local Development: Run environments locally using Docker (Remote Docker coming soon)
- βοΈ Cloud Deployment: Deploy to Fly.io's global platform (AWS, GCE, Digital Ocean coming soon).
- π€ AI-Ready: Pre-configured with Claude Code and Gemini CLI, plus easy API key setup for Anthropic, Gemini, and OpenAI
- π» Editor Sync: Automatically detect and copy VS Code/Cursor settings & extensions
- π Secure: SSH key support for private Git repositories with auto-generated VS Code passwords
- β‘ Fast Setup: One command deployment with smart defaults and guided setup wizard
- π Interactive & Automated: Full CLI with
-yflag for CI/CD - π Flexible: Upload folders or work with empty environments
- π§ Cross-Platform: Works on macOS, Windows, and Linux (Untested on Linux and Windows)
pip install opencodespace# Interactive setup with editor detection (recommended)
opencodespace
# Non-interactive with defaults (skips editor config)
opencodespace -y
# Deploy specific directory
opencodespace deploy /path/to/project
# Deploy with specific platform
opencodespace deploy --platform fly# Stop environment
opencodespace stop
# Remove environment completely
opencodespace remove
# List available providers
opencodespace --list-providers| Command | Description |
|---|---|
opencodespace |
Deploy current directory with interactive setup |
opencodespace deploy [path] |
Deploy specific directory |
opencodespace stop [path] |
Stop the environment |
opencodespace remove [path] |
Remove the environment |
| Option | Description |
|---|---|
-y, --yes |
Skip interactive prompts, use defaults (no editor config) |
--list-providers |
Show available deployment providers |
-v, --version |
Show version information |
# Full interactive setup with editor detection
opencodespace
# Quick deployment with defaults (no editor sync)
opencodespace -y
# Deploy to specific platform
opencodespace deploy --platform local
# Deploy with editor configuration for specific directory
opencodespace deploy /path/to/my-projectNote: Run the interactive setup wizard to generate .opencodespace/config.toml
| Option | Default | Description |
|---|---|---|
name |
Auto-generated | Environment name |
platform |
"local" |
Deployment platform (local or fly) |
upload_folder |
true |
Upload current directory to container |
git_branching |
true |
Enable Git branch management |
dockerfile |
"Dockerfile" |
Custom Dockerfile name |
vscode_password |
Auto-generated | VS Code/Coder access password |
api_keys |
[] |
Legacy environment variables list (use ai_api_keys instead) |
ai_api_keys.ANTHROPIC_API_KEY |
"" |
Anthropic (Claude) API key |
ai_api_keys.GEMINI_API_KEY |
"" |
Google Gemini API key |
ai_api_keys.OPENAI_API_KEY |
"" |
OpenAI (ChatGPT) API key |
| Option | Default | Description |
|---|---|---|
vscode_config.copy_settings |
false |
Copy editor settings to remote |
vscode_config.copy_extensions |
false |
Install extensions in remote |
vscode_config.detected_editors |
[] |
List of detected editors |
vscode_config.*_settings_path |
null |
Path to local settings file |
vscode_config.*_extensions_list |
[] |
List of extensions to install |
- Python 3.7+
- Docker - Install Docker Desktop
- Python 3.7+
- flyctl - Install flyctl
- VS Code and/or Cursor installed locally (optional)
- Extensions accessible via
code --list-extensionsorcursor --list-extensions
Perfect for testing with your complete development setup:
# Interactive setup with editor detection
opencodespace
# Manual configuration for local platform
opencodespace deploy --platform localYour remote environment will have:
- β All your installed extensions
- β Your settings.json configuration
- β Your themes and preferences
- β Language-specific settings
Deploy to Fly.io with your complete editor configuration:
# Interactive setup for cloud deployment
opencodespace
# Configure platform during setup
> Select platform: fly.io
# Access your fully configured environment
# at https://your-app.fly.devPre-configured with AI tools, automatic password generation, and your editor setup:
# Full setup with AI tools and editor config
opencodespace
# During interactive setup, you'll configure:
# - Secure auto-generated VS Code password
# - VS Code/Cursor settings & extensions
# - AI API keys (Anthropic, Gemini, OpenAI)
# - Git repository access
# - SSH keys for private reposYour environment will include:
- β Secure Access: Auto-generated password for VS Code/Coder
- β AI Integration: API keys available as environment variables
- β Complete Setup: Your editor preferences and extensions
Secure access to private repos with your development environment:
# Interactive setup handles everything
opencodespace
# Setup wizard will:
# 1. Detect your editors
# 2. Offer to copy settings/extensions
# 3. Configure SSH keys for Git access
# 4. Set up repository cloningShare consistent development environments:
# Each team member gets the same setup
opencodespace
# Everyone can optionally overlay their own:
# - Editor preferences
# - Extension sets
# - Personal settings- Auto-Generated Passwords: VS Code/Coder passwords are automatically generated during setup
- Password Storage: Passwords are saved in your
.opencodespace/config.tomlfor reference - Password Display: The password is displayed prominently during setup and after deployment
- Structured Setup: AI API keys are now configured in the dedicated
[ai_api_keys]section - Environment Variables: Keys are automatically available as environment variables in your container
- Supported Services: Anthropic (Claude), Google Gemini, and OpenAI (ChatGPT)
- Optional Configuration: All AI API keys are optional and can be configured later
- Interactive Mode: Editor detection and configuration only happens during interactive setup
- Non-Interactive Mode: Use
opencodespace -yto skip editor configuration for CI/CD - Multiple Editors: If both VS Code and Cursor are detected, you can choose to copy from both
- Extension Compatibility: Cursor extensions are compatible with VS Code and will be installed
When both SSH key and folder upload are disabled:
β οΈ Warning: No SSH key provided and folder upload disabled.
The container will start with an empty workspace and no git access.
Consider enabling folder upload or providing an SSH key for git operations.- Local:
opencodespace-{name} - Fly.io: Uses the app name directly
opencodespace/
βββ src/opencodespace/ # Modern src layout
β βββ main.py # CLI with editor detection
β βββ providers/ # Platform providers
β βββ .opencodespace/ # Docker templates with editor setup
βββ setup.py # Package configuration
βββ README.md # This file
During interactive setup, you can configure AI API keys for popular services:
- Anthropic (Claude): For Claude AI development assistance
- Google Gemini: For Google's Gemini AI models
- OpenAI (ChatGPT): For OpenAI's GPT models
These keys are securely stored in your config and available as environment variables in your development environment, making it easy to use AI tools directly in your code.
This project includes a comprehensive build system with multiple interfaces for development tasks.
git clone https://github.com/ngramai/opencodespace.git
cd opencodespace
# Install dependencies and package in development mode
make install
# or: python dev-build.py install
# or: ./build.sh install
# Run quick tests during development
make test-quick
# or: python dev-build.py test --quick
# or: ./build.sh test-quickThree equivalent interfaces for development tasks:
python dev-build.py [command]- Feature-rich Python script (cross-platform)make [target]- Traditional Makefile interface (Unix/Linux)./build.sh [command]- Simple shell script wrapper
| Command | Description |
|---|---|
install |
Install dependencies and package in development mode |
test |
Run the complete test suite |
test-quick |
Run quick tests (recommended for development) |
clean |
Clean build artifacts and cache files |
build |
Build package for distribution |
lint |
Run code quality checks |
all |
Run complete build pipeline |
# Development workflow
make install # Set up development environment
make test-quick # Test your changes
make all # Full build pipeline before PR
# Building for distribution
make clean
make build
# Get help
python dev-dev-build.py help
make help
./build.sh helpFor detailed documentation, see BUILD.md.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
β€οΈ from ngram