Ephemeral Docker Compose environments on DigitalOcean
A practical architecture for launching a real Compose stack only when a developer needs it, without exposing its services publicly.
Local Docker Compose is excellent until a teammate, client, or CI run needs a stack that survives your laptop. The usual next step is a permanent staging server. That solves reachability, but it also creates idle spend, shared-state collisions, and another machine nobody is sure they can delete.
Chalupa takes a narrower approach: infer a selected stack from the Compose file, launch it in the developer's own DigitalOcean account, and tear down compute when the work is finished.
Keep Compose as the source of truth
A preview system should not require a second handwritten inventory of services, ports, dependencies, and volumes. Chalupa reads those facts from Compose and applies only explicit, project-owned overrides from chalupa.yml.
The result can be previewed offline before any provider operation. That matters because infrastructure validation should be free, deterministic, and safe to repeat.
Make private the default topology
Every service port binds to 127.0.0.1 on the droplet. Only SSH is admitted through the cloud firewall. Developers reach databases and internal tools through an SSH tunnel instead of turning temporary services into public endpoints.
This topology is intentionally boring: fewer public listeners mean fewer credentials, dashboards, and accidental test databases exposed to the internet.
Separate compute from useful data
Disposable compute does not imply disposable seed data. Chalupa places optional block storage in a separate Pulumi stack. Destroying the droplet leaves the volume intact; deleting that volume requires a different, explicit destructive operation.
The practical outcome is a fast loop: seed once, launch when needed, tear down compute, and attach the same protected data next time.
Measure the complete lifecycle
The useful unit is not “servers created.” It is a verified cycle from launch to safe teardown. A hosted control plane can show activity, stale signals, test evidence, and estimated provider cost while the infrastructure itself remains in the customer's account.
Start with the offline quickstart, then compare the hosted plans.