Skip to content

Docker Setup

Terminal window
docker run -d \
-p 8080:8080 \
-v pong-data:/app/data \
-e ADMIN_API_KEY=pong_mykey \
ghcr.io/getpong/pong-backend-go:latest

Create a docker-compose.yml:

services:
pong:
image: ghcr.io/getpong/pong-backend-go:latest
ports:
- "8080:8080"
volumes:
- pong-data:/app/data
env_file: .env
restart: unless-stopped
volumes:
pong-data:

Create a .env file (see Configuration):

Terminal window
ADMIN_API_KEY=pong_mykey
# Optional: enable HTTP auth on monitors (generate with: openssl rand -hex 32)
# ENCRYPTION_KEY=your-64-char-hex-key

Start it:

Terminal window
docker compose up -d
Terminal window
git clone https://github.com/getpong/pong-backend-go.git
cd pong-backend-go
docker build -t pong .
docker run -d -p 8080:8080 -v pong-data:/app/data --env-file .env pong

All data is stored in a single SQLite file at /app/data/ghm.db inside the container. Mount a volume to persist it across restarts.

Terminal window
docker compose pull
docker compose up -d

Migrations run automatically on startup.