Launch pricingNo GST added. What you see is what you pay.

Deploy apps · 10 min

Run apps with Docker Compose

Install Docker and run one or more containers from a single compose file.

Docker Compose runs your app and everything it needs (a database, a cache) from one file, the same way on your laptop and your server.

1. Install Docker

bash
curl -fsSL https://get.docker.com | sudo sh
sudo usermod -aG docker $USER

Sign out and back in so you can run docker without sudo.

2. Write a compose file

Here's an example: a web app with a PostgreSQL database.

yaml
services:
  app:
    image: ghcr.io/you/your-app:latest
    restart: always
    ports:
      - "80:3000"
    environment:
      DATABASE_URL: postgres://app:change-me@db:5432/app
    depends_on: [db]
  db:
    image: postgres:16
    restart: always
    environment:
      POSTGRES_USER: app
      POSTGRES_PASSWORD: change-me
      POSTGRES_DB: app
    volumes:
      - db:/var/lib/postgresql/data
volumes:
  db: {}

Save it as docker-compose.yml in a folder like /opt/myapp.

3. Start it

bash
cd /opt/myapp
docker compose up -d

restart: always brings the containers back after a reboot.

Everyday commands

bash
docker compose ps          # what's running
docker compose logs -f app # follow the app's logs
docker compose pull && docker compose up -d   # update to new images

Stuck? Contact us or open a support ticket from your panel.