---
title: "Docker hosting on Edge | Compose on real VMs"
description: "Run Docker and Docker Compose on Edge VMs. Any image, any language, a global CDN in front and S3-compatible storage for state, with zero egress fees."
url: https://edge.network/solutions/docker
---

For Docker

# Any container, on a VM you control

Create a VM with Docker preinstalled, run your compose file and put a CDN across 988 locations in front of it. No proprietary runtime, no registry lock-in, no egress fees.

[Deploy a VM](/console/access/new?product=compute)[Read the startup script docs](/docs/compute/scripts)

The setup on this page costs $40.72 a month, with no egress line.

Why Docker on Edge

## The architecture on your whiteboard, running

Real VMs you control, sized to fit, with a global network already wired in. Nothing between you and docker compose.

-   ### Plain Docker, plain Linux
    
    The docker library script installs Docker CE and Compose on first boot. No proprietary container runtime, no special registry.
    
-   ### Compose-ready
    
    docker compose up -d works exactly as it does on your laptop. Multi-container apps, shared networks and named volumes, straight from your repo.
    
-   ### State that outlives containers
    
    Keep databases on named volumes on local NVMe, and push uploads and backups to S3-compatible Edge Storage. Containers stay disposable.
    
-   ### Global delivery, zero egress
    
    Put the CDN in front and your static responses are cached in 988 locations. Bandwidth out to users is never billed.
    
-   ### Bootstrap from one script
    
    Pass --script to install Docker, pull images and start the stack on first boot. Repeatable and kept in version control.
    
-   ### Hand the compose file to your agent
    
    "Deploy this compose file to app.acme.dev." The agent API stands up the VM, configures DNS and adds a CDN deployment.
    

Reference architecture

## Your whole compose file on one VM

One VM runs the Docker daemon and your whole compose file. Data sits on NVMe volumes, backups go to a bucket and the CDN takes the public traffic.

-   [Compute](/compute)
    
    Hosts the Docker daemon and every container in your compose file.
    
-   [Storage](/storage)
    
    S3-compatible store for uploads, backups and build artefacts.
    
-   [CDN](/cdn)
    
    Caches the static responses your containers serve, with zero egress.
    
-   [DNS](/dns)
    
    Anycast DNS for routing and per-environment subdomains.
    

Deploy

## From compose.yml to live in four steps

Everything here is standard Docker. If it runs on your laptop, it runs on the VM.

1.  01
    
    ### Create a VM with Docker
    
    The docker library script installs Docker CE and the Compose plugin on first boot, before you can even SSH in.
    
    shell
    
    ```
    $ edge compute create --name stack --size s-4vcpu-8gb \
        --image ubuntu-24 --region london --script docker
    ```
    
2.  02
    
    ### Describe the stack
    
    No bind mounts, so the same file deploys from your laptop over SSH. Postgres data lives on a named volume.
    
    compose.yml
    
    ```
    services:
      app:
        image: ghcr.io/acme/app:latest
        restart: unless-stopped
        env_file: .env
        ports: ["80:3000"]
        depends_on: [db, redis]
      worker:
        image: ghcr.io/acme/app:latest
        command: ["./bin/worker"]
        restart: unless-stopped
        env_file: .env
      db:
        image: postgres:16
        restart: unless-stopped
        env_file: .env
        volumes: ["pgdata:/var/lib/postgresql/data"]
        healthcheck:
          test: ["CMD", "pg_isready", "-U", "postgres"]
      redis:
        image: redis:7
        restart: unless-stopped
    volumes:
      pgdata:
    ```
    
3.  03
    
    ### Ship it over SSH
    
    A Docker context runs your local docker commands against the VM. Updates are a pull and an up -d.
    
    shell
    
    ```
    $ docker context create edge --docker host=ssh://root@<vm-ip>
    $ docker --context edge compose pull
    $ docker --context edge compose up -d
    ```
    
4.  04
    
    ### Front it with the CDN
    
    The CDN talks to the app container's published port. Point your domain's CNAME at cdn.edge.network and SSL follows.
    
    shell
    
    ```
    $ edge cdn create --name acme-stack
    $ edge cdn domains add cdn-d83c15 \
        --domain app.acme.dev \
        --origin http://<vm-ip>
    ```
    

Prefer to hand it off? [Give the job to your AI agent](/solutions/agentic-development) or [have our engineers do it](/solutions/expert-services).

What it costs

## One VM, the whole compose file

No per-container or control-plane charge. You pay for the VM the containers share, plus what's in the bucket.

-   No per-container or control-plane fees
-   No egress fees from the VM, CDN or bucket
-   Resize the VM with one command as the stack grows

[See compute pricing](/compute/pricing)

Estimated monthly bill on Edge

Four-container stack, 3.5M requests a month, 105 GB of backups

USD

-   Compute$38.47Performance VM, 4 vCPU, 8 GiB, 160 GB NVMe
-   CDN$0.753.5M requests: first 500k free, 3M × $0.25 per million
-   Storage$1.50105 GB of backups: first 5 GB free, 100 GB × $0.015
-   DNS$0.00Production and staging records
-   Egress$0.00

Total$40.72

FAQ

## Compose, images and volumes

Something else? [Ask an engineer](/contact).

Can I use Docker Compose?

Yes, unchanged. Commit your compose file, create a VM with the docker library script and run docker compose up -d, either on the VM or from your laptop through a Docker context.

What about Kubernetes?

You can run k3s or full Kubernetes yourself on a cluster of Edge VMs. For most workloads under twenty or so containers, Compose on one or two VMs is far simpler to run.

Where do my images live?

Wherever you like: Docker Hub, GHCR, GitLab's registry or your own. To keep images in-house, run the open-source registry image with its S3 storage driver pointed at an Edge Storage bucket.

How do I update a running container?

The standard way: pull the new image and run docker compose up -d, which recreates only what changed. Wrap it in a CI step, or use a Watchtower-style updater. The VM is yours.

How do I back up volumes?

Dump databases on a schedule and copy the file to Edge Storage with any S3 client. For whole-VM protection, add backups or snapshots from the Compute dashboard.

Drop-in services

## Add-ons that don't need another container

-   [
    
    Edge ShieldBot protection`POST /siteverify → score: 94`
    
    Invisible bot protection for logins, signups and forms: a 1–100 humanity score instead of a puzzle, from one HTTP call in any container.
    
    Free forever, with unlimited widgets. No puzzles for visitors.Explore
    
    ](/shield)
-   [
    
    Edge AssistAI answers`<script src="…/assist.js">`
    
    An AI answer box grounded in your own content. One script tag, whatever runs in the containers.
    
    Free tier: 250 answered questions a monthExplore
    
    ](/assist)

Related stacks

## What people run in their containers

[All 38 stacks](/solutions/stacks)

-   [Kubernetesk3s and full k8s, no control-plane fees](/solutions/kubernetes)
-   [Node.jsExpress, Fastify or Hono on your own runtime](/solutions/nodejs)
-   [Next.jsSelf-host Next.js without the lock-in](/solutions/nextjs)
-   [PostgreSQLSelf-hosted Postgres on dedicated NVMe](/solutions/postgresql)

## docker compose up, on Edge

Bring your compose file. We'll run it on a VM you control, with the network already wired in.

[Deploy a VM](/console/access/new?product=compute)[Talk to an engineer](/contact)

Billed hourly from a prepaid balance. Egress is free on every product.
