stremio/deploy/docker/docker-compose.dokploy.yml
Jos Vooges | STH db8e3e572f Add OMDb admin settings and poster API for IMDb metadata.
Store the key encrypted in the DB (not git) and proxy OMDb posters so clients never see the API key.
2026-09-16 23:33:01 +02:00

108 lines
3.2 KiB
YAML

# Docker Compose for Dokploy
# Compose path: deploy/docker/docker-compose.dokploy.yml
#
# Put secrets in Dokploy Environment tab (NOT env_file).
# Dokploy injects them for ${VAR} substitution.
services:
postgres:
image: postgres:16-alpine
restart: unless-stopped
environment:
POSTGRES_USER: ${POSTGRES_USER:-media}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?POSTGRES_PASSWORD is required}
POSTGRES_DB: ${POSTGRES_DB:-media_cluster}
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U \"$$POSTGRES_USER\" -d \"$$POSTGRES_DB\""]
interval: 10s
timeout: 5s
retries: 10
start_period: 10s
networks:
- media-cluster
redis:
image: redis:7-alpine
restart: unless-stopped
volumes:
- redis_data:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 10
networks:
- media-cluster
master-api:
build:
context: ../..
dockerfile: deploy/docker/Dockerfile.master-api
restart: unless-stopped
environment:
NODE_ENV: production
HOST: 0.0.0.0
PORT: "3000"
DATABASE_URL: postgresql://${POSTGRES_USER:-media}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_DB:-media_cluster}
REDIS_URL: redis://redis:6379
SESSION_SECRET: ${SESSION_SECRET:?SESSION_SECRET is required}
ADMIN_EMAIL: ${ADMIN_EMAIL:-admin@localhost}
ADMIN_PASSWORD: ${ADMIN_PASSWORD:-changeme123}
PUBLIC_URL: ${PUBLIC_URL:-https://master.vonas.nl}
# Koppel-URL in apps (/link). Zonder dit valt de API terug op PUBLIC_URL (master).
CLIENT_LINK_BASE_URL: ${CLIENT_LINK_BASE_URL:-https://admin.vonas.nl}
TMDB_API_KEY: ${TMDB_API_KEY:-}
OMDB_API_KEY: ${OMDB_API_KEY:-}
PLAYBACK_IDLE_TIMEOUT_SECONDS: ${PLAYBACK_IDLE_TIMEOUT_SECONDS:-1200}
PLAYBACK_ABSOLUTE_LIFETIME_SECONDS: ${PLAYBACK_ABSOLUTE_LIFETIME_SECONDS:-43200}
NODE_HEARTBEAT_INTERVAL_SECONDS: ${NODE_HEARTBEAT_INTERVAL_SECONDS:-30}
NODE_OFFLINE_THRESHOLD_SECONDS: ${NODE_OFFLINE_THRESHOLD_SECONDS:-90}
HIDE_UNAVAILABLE_TITLES: ${HIDE_UNAVAILABLE_TITLES:-true}
# Rijke EPG (programma-images/desc) — los van XUI short_epg
IPTV_EPG_XML_URL: ${IPTV_EPG_XML_URL:-https://epg.faabserver.nl/epg/odido.xml}
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
ports:
- "3100:3000"
healthcheck:
test: ["CMD", "wget", "-qO-", "http://127.0.0.1:3000/health"]
interval: 15s
timeout: 5s
retries: 10
start_period: 90s
networks:
media-cluster:
aliases:
- master-api
admin-ui:
build:
context: ../..
dockerfile: deploy/docker/Dockerfile.admin-ui
restart: unless-stopped
extra_hosts:
- "host.docker.internal:host-gateway"
environment:
HOSTNAME: 0.0.0.0
PORT: "3000"
MASTER_API_URL: http://master-api:3000
NEXT_PUBLIC_API_URL: http://master-api:3000
depends_on:
- master-api
ports:
- "3101:3000"
networks:
- media-cluster
volumes:
postgres_data:
redis_data:
networks:
media-cluster:
driver: bridge