_ _
__| | ___ ___| | __
/ _` |/ _ \ / __| |/ /
| (_| | (_) | (__| <
\__,_|\___/ \___|_|\_\
Disposable Remote Development Environments
Your laptop stays cool. Your cloud does the work.
Create | Work | Stop | Resume | Destroy
Zero local resource consumption. Full control. Pay only for what you use.
Running Docker and Kubernetes locally drains your battery, spins up fans, and turns your laptop into a space heater. dock moves all that to a remote VM you fully control.
| Local Dev | dock | |
|---|---|---|
| CPU usage | High | Zero |
| Battery drain | Yes | No |
| Fan noise | Loud | Silent |
| Cost when idle | N/A | $0 |
| Reproducible | Maybe | Always |
curl -fsSL https://raw.githubusercontent.com/jiraguha/dock/main/install.sh | bashdock env --set SCW_ACCESS_KEY=SCWXXXXXXXXX,SCW_SECRET_KEY=xxx-xxx-xxx,SCW_PROJECT_ID=xxx-xxx-xxxOr create ~/.dock/.env:
mkdir -p ~/.dock
cat > ~/.dock/.env << 'EOF'
SCW_ACCESS_KEY=SCWXXXXXXXXXXXXXXXXX
SCW_SECRET_KEY=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
SCW_PROJECT_ID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
EOFdock createThat's it! Auto-pilot mode handles SSH multiplexing, port forwarding, and environment setup automatically.
dock ssh # SSH into your environment
docker ps # Docker works automatically
kubectl get nodes # Kubernetes works automaticallydock ⛴ Environment Status
─────────────────────────────────────
State: 🟢 running
Instance: DEV1-M
Zone: fr-par-1
IP: 163.172.189.201
Uptime: 2h 34m
Branch: root/main
─────────────────────────────────────
Docker: ✓ connected
Kubernetes: ✓ k3s (6 pods)
SSH: ✓ master active
Ports: 3000, 8080, 5432
─────────────────────────────────────
🚀 Creating environment
✓ Terraform initialized
✓ Instance provisioned (DEV1-M, fr-par-1)
✓ SSH available at 163.172.189.201
✓ Docker configured
✓ Kubernetes ready (k3s)
✓ Port forwarding active
✅ Environment created in 00:02:41
⚠️ Destroy environment?
Instance DEV1-M
Zone fr-par-1
IP 163.172.189.201
This will permanently delete all data.
? Continue? (y/N) y
🗑️ Destroying environment
✓ Port forwarding stopped
✓ SSH connections closed
✓ Instance terminated
✓ Resources cleaned up
✅ Environment destroyed in 00:00:15
Zero resources running. Zero cost.
Use --yes or -y to skip confirmation:
dock destroy --yes- Terraform CLI
- Scaleway CLI (
scw) - Scaleway API credentials
- SSH key pair (
~/.ssh/id_ed25519or~/.ssh/id_rsa)
Pipeline and nightly workflows use the following repository secrets:
| Secret | Required for | Description |
|---|---|---|
SCW_ACCESS_KEY |
Tests + Nightly e2e jobs | Scaleway access key |
SCW_SECRET_KEY |
Tests + Nightly e2e jobs | Scaleway secret key |
SCW_PROJECT_ID |
Tests + Nightly e2e jobs | Scaleway project ID |
DISCORD_INSIGHTS_WEBHOOK |
Tests workflow notifications | Discord webhook for #pipeline-insights |
DISCORD_ISSUES_WEBHOOK |
Tests + Nightly notifications | Discord webhook for #issues alerts |
SLACK_WEBHOOK |
Nightly notifications | Slack webhook for #dock-security nightly report |
dock create # Create new environment
dock start # Power on stopped environment
dock stop # Power off (preserves data)
dock reboot # Reboot running environment
dock destroy # Delete everything (zero cost)
dock status # Show current statedock ssh # Open SSH shell
dock ssh "docker ps" # Run remote commanddock portforward # Forward ports (foreground)
dock portforward -d # Forward ports (background)
dock portforward --stop # Stop background tunnelBy default, dock runs in auto-pilot mode, which automatically handles connection setup after dock create and dock start.
After dock create or dock start completes:
| Action | Equivalent Manual Command |
|---|---|
| SSH multiplexing setup | dock ssh-config --start-master |
| Port forwarding (background) | dock portforward -d |
| Docker environment | export DOCKER_HOST=ssh://root@<ip> |
| Kubernetes config | export KUBECONFIG=~/.kube/dock-config |
| Command | Auto-pilot actions |
|---|---|
dock create |
Full setup (SSH + ports + Docker + K8s) |
dock start |
Reconnect all services |
dock stop |
Clean up connections |
dock destroy |
Clean up connections |
Run dock init once to add auto-pilot integration to your shell. This sources ~/.dock/dock.init which automatically sets environment variables when dock is running.
dock env --set AUTO_PILOT=falseWhen disabled, you manage connections manually:
dock create
dock ssh-config --start-master
dock portforward -d
eval $(dock docker-env)
export KUBECONFIG=~/.kube/dock-configCheckpoint your environment and branch into isolated lineages — like git, but for your whole machine.
dock snap # Save current state to active branch
dock snap --branch feature-x # Fork into a new branchdock create --snapshot # Pick and restore a snapshot interactivelydock snap --tree # Show full branch + snapshot tree
dock snap --tree root/main # Scope to a branch and its descendantsdock snap --list # All branches with snapshot history
dock snap --list root/main # Scoped to a branch
dock snap --current # Print active branch pathSnapshots preserve:
- Installed packages and tools
- Docker images and containers
- Configuration files
- Everything on the disk
dock envdock env --set SCW_INSTANCE_TYPE=DEV1-L,SCW_ZONE=fr-par-2dock env --unset SCW_INSTANCE_NAME| Variable | Default | Description |
|---|---|---|
SCW_ACCESS_KEY |
(required) | Scaleway access key |
SCW_SECRET_KEY |
(required) | Scaleway secret key |
SCW_PROJECT_ID |
(required) | Scaleway project ID |
SCW_REGION |
fr-par |
Scaleway region |
SCW_ZONE |
fr-par-1 |
Scaleway zone |
SCW_INSTANCE_TYPE |
DEV1-M |
Instance type (see below) |
SCW_INSTANCE_IMAGE |
(auto) | Instance image |
SCW_INSTANCE_NAME |
dock-env |
Instance name |
SSH_PUBLIC_KEY_PATH |
~/.ssh/id_ed25519.pub |
SSH public key |
SSH_PRIVATE_KEY_PATH |
~/.ssh/id_ed25519 |
SSH private key |
K8S_ENGINE |
k3s |
Kubernetes: k3s or kind |
FORWARD_PORTS |
8080,3000,5432,6379,27017 |
Ports to forward |
AUTO_PILOT |
true |
Enable auto-pilot mode |
| Variable | Default | Description |
|---|---|---|
DOCK_NONINTERACTIVE |
0 |
Set to 1 to disable all prompts (for CI/scripts) |
DOCK_VERBOSE |
0 |
Set to 1 to enable verbose output |
NO_COLOR |
0 |
Set to 1 to disable colored output |
| Type | vCPU | RAM | Best for |
|---|---|---|---|
DEV1-S |
2 | 2GB | Light development |
DEV1-M |
3 | 4GB | Standard development |
DEV1-L |
4 | 8GB | Heavy workloads |
DEV1-XL |
4 | 12GB | Large projects |
L4-1-24G |
8 | 48GB | GPU/ML workloads |
# Simple mode (SSH per command)
eval $(dock docker-env)
docker ps
# Tunnel mode (single connection, faster for heavy use)
dock docker-tunnel -d
export DOCKER_HOST=unix://~/.dock/sockets/docker.sock
docker psdock kubeconfig
export KUBECONFIG=~/.kube/dock-config
kubectl get nodesdock ssh-config # Set up SSH multiplexing
dock ssh-config --start-master # Start master connection
dock configure # Apply SSH server settings
dock configure --show # Show remote SSH configdock connection # Show connection status
dock connection --refresh # Restart all connections
dock connection --clean # Stop all connectionsdock analytics # Show usage summary
dock analytics --last # Show last 10 operations
dock analytics --all # Show all operationsdock init # Set up shell integration (auto-pilot env vars)
dock autocomplete # Set up tab completion| Command | Description |
|---|---|
dock create |
Create and provision environment |
dock create --snapshot |
Create from snapshot (fast) |
dock destroy |
Destroy all resources |
dock status |
Show current state |
dock start |
Power on stopped environment |
dock stop |
Gracefully shut down |
dock reboot |
Reboot running environment |
dock ssh [cmd] |
SSH into environment |
dock kubeconfig |
Fetch/update kubeconfig |
dock docker-env |
Print DOCKER_HOST export |
dock docker-tunnel |
Forward Docker socket |
dock portforward |
Forward ports |
dock configure |
Apply SSH config to remote |
dock connection |
Manage connections |
dock snap |
Checkpoint environment; branch and inspect snapshot tree |
dock env |
Manage environment variables |
dock analytics |
View usage statistics |
dock init |
Set up shell integration |
dock autocomplete |
Set up tab completion |
dock upgrade |
Upgrade to latest version or tracked stream (--track=<branch>) |
dock version |
Show version |
Use dock <command> --help for detailed help on any command.
| State | Cost |
|---|---|
| Running | ~€7.99/month (DEV1-M) |
| Stopped | ~€1.60/month (disk only) |
| Destroyed | €0 |
┌──────────────┐
│ dock CLI │ ← Bun/TypeScript
└──────┬───────┘
│
▼
┌──────────────────────────┐
│ Terraform + scw │ ← IaC layer
└──────┬───────────────────┘
│
▼
┌──────────────────────────┐
│ Scaleway Instance │
│ - Ubuntu 22.04 │
│ - Docker │
│ - k3s │
└──────────────────────────┘
curl -fsSL https://raw.githubusercontent.com/jiraguha/dock/main/install.sh | bashDownload from Releases:
| Platform | Binary |
|---|---|
| Linux x64 | dock-linux-x64 |
| Linux ARM64 | dock-linux-arm64 |
| macOS x64 | dock-darwin-x64 |
| macOS ARM64 | dock-darwin-arm64 |
chmod +x dock-*
sudo mv dock-* /usr/local/bin/dockgit clone https://github.com/jiraguha/dock.git
cd dock
bun install
./bin/dock --help- Automatic Shutdown (Kill Switch) — Heartbeat mechanism to auto-shutdown inactive machines; destroy after 1 week of inactivity (3)
- Single Executable CLI — Package CLI as a self-contained executable
- Self-Upgrading CLI — Automatic updates to latest version
- File Transfer (send/fetch) — Simple file upload/download commands for quick file transfers (2)
- Bidirectional Directory Sync — Real-time sync between local and remote directories
- Beautiful CLI UX — Enhanced CLI with spinners, colors, progress tracking, and consistent output (@clack/prompts + picocolors)
- OpenClaw Safe Mode — Restrict actions to safe, reversible, or sandboxed operations
- MCP Integration — Machine Control Protocol for advanced lifecycle management
- Multi-Environment Support — Manage multiple isolated environments (dev, staging, prod)
- Multi-Provider VM Support — AWS, GCP, Azure, and other providers (1:gcp)
- Web UI — Web interface for managing environments and machines
- NixOS Integration — Declarative, reproducible development environments with Nix
- Claude Code Integration — AI-assisted development workflow with Claude Code
MIT