Two-container stack (umami + postgres) deployed to the hetzner host via a remote Docker context, attached to npm_default so Nginx Proxy Manager fronts stats.gethumanai.pl. Secrets live in a gitignored .env. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
55 lines
1.3 KiB
YAML
55 lines
1.3 KiB
YAML
name: umami
|
|
|
|
services:
|
|
umami:
|
|
image: ghcr.io/umami-software/umami:postgresql-latest
|
|
container_name: umami
|
|
restart: unless-stopped
|
|
environment:
|
|
DATABASE_TYPE: postgresql
|
|
DATABASE_URL: postgresql://umami:${POSTGRES_PASSWORD}@umami-db:5432/umami
|
|
APP_SECRET: ${APP_SECRET}
|
|
depends_on:
|
|
umami-db:
|
|
condition: service_healthy
|
|
networks:
|
|
- internal
|
|
- npm
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "curl -f http://localhost:3000/api/heartbeat || exit 1"]
|
|
interval: 15s
|
|
timeout: 5s
|
|
retries: 10
|
|
start_period: 40s
|
|
|
|
umami-db:
|
|
image: postgres:16-alpine
|
|
container_name: umami-db
|
|
restart: unless-stopped
|
|
environment:
|
|
POSTGRES_DB: umami
|
|
POSTGRES_USER: umami
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
|
volumes:
|
|
- umami-db-data:/var/lib/postgresql/data
|
|
networks:
|
|
- internal
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U umami -d umami"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 10
|
|
start_period: 20s
|
|
|
|
volumes:
|
|
umami-db-data:
|
|
|
|
networks:
|
|
# Internal-only network for umami <-> postgres traffic.
|
|
internal:
|
|
# Shared network with Nginx Proxy Manager so it can reach `umami:3000`
|
|
# by container name. No host port is published.
|
|
npm:
|
|
external: true
|
|
name: npm_default
|