2025-11-08 22:34:46 +01:00
|
|
|
services:
|
|
|
|
|
# PostgreSQL with pgvector for AI/RAG workloads
|
2025-11-08 22:35:41 +01:00
|
|
|
ai_postgres:
|
2025-11-08 22:34:46 +01:00
|
|
|
image: ${AI_POSTGRES_IMAGE:-pgvector/pgvector:pg16}
|
|
|
|
|
container_name: ${AI_COMPOSE_PROJECT_NAME}_postgres
|
|
|
|
|
restart: unless-stopped
|
|
|
|
|
environment:
|
|
|
|
|
TZ: ${TIMEZONE:-Europe/Berlin}
|
|
|
|
|
POSTGRES_USER: ${AI_DB_USER}
|
|
|
|
|
POSTGRES_PASSWORD: ${AI_DB_PASSWORD}
|
|
|
|
|
POSTGRES_DB: ${AI_DB_NAME}
|
|
|
|
|
POSTGRES_HOST_AUTH_METHOD: scram-sha-256
|
|
|
|
|
POSTGRES_INITDB_ARGS: --auth-host=scram-sha-256
|
|
|
|
|
volumes:
|
|
|
|
|
- ai_postgres_data:/var/lib/postgresql/data
|
2025-11-09 18:36:50 +01:00
|
|
|
- ./postgres/init:/docker-entrypoint-initdb.d
|
2025-11-08 22:34:46 +01:00
|
|
|
healthcheck:
|
2025-11-26 22:54:10 +01:00
|
|
|
test: ["CMD-SHELL", "pg_isready -U ${AI_DB_USER}"]
|
2025-11-08 22:34:46 +01:00
|
|
|
interval: 30s
|
|
|
|
|
timeout: 10s
|
|
|
|
|
retries: 3
|
|
|
|
|
start_period: 40s
|
|
|
|
|
networks:
|
|
|
|
|
- compose_network
|
|
|
|
|
|
|
|
|
|
# Open WebUI - ChatGPT-like interface for AI models
|
|
|
|
|
webui:
|
2025-11-08 23:15:27 +01:00
|
|
|
image: ${AI_WEBUI_IMAGE:-ghcr.io/open-webui/open-webui:main}
|
2025-11-08 22:34:46 +01:00
|
|
|
container_name: ${AI_COMPOSE_PROJECT_NAME}_webui
|
|
|
|
|
restart: unless-stopped
|
|
|
|
|
environment:
|
|
|
|
|
TZ: ${TIMEZONE:-Europe/Berlin}
|
|
|
|
|
|
|
|
|
|
# Database configuration
|
2025-11-08 22:35:41 +01:00
|
|
|
DATABASE_URL: postgresql://${AI_DB_USER}:${AI_DB_PASSWORD}@ai_postgres:5432/${AI_DB_NAME}
|
2025-11-08 22:34:46 +01:00
|
|
|
|
2025-11-21 18:42:46 +01:00
|
|
|
# OpenAI API configuration (pointing to LiteLLM proxy)
|
|
|
|
|
OPENAI_API_BASE_URLS: http://litellm:4000
|
|
|
|
|
OPENAI_API_KEYS: ${AI_LITELLM_API_KEY}
|
2025-11-08 22:34:46 +01:00
|
|
|
|
2025-11-21 16:57:20 +01:00
|
|
|
# Disable Ollama (we only use LiteLLM)
|
|
|
|
|
ENABLE_OLLAMA_API: false
|
|
|
|
|
OLLAMA_BASE_URLS: ""
|
|
|
|
|
|
2025-11-08 22:34:46 +01:00
|
|
|
# WebUI configuration
|
|
|
|
|
WEBUI_NAME: ${AI_WEBUI_NAME:-Pivoine AI}
|
|
|
|
|
WEBUI_URL: https://${AI_TRAEFIK_HOST}
|
|
|
|
|
WEBUI_SECRET_KEY: ${AI_WEBUI_SECRET_KEY}
|
|
|
|
|
|
|
|
|
|
# Feature flags
|
|
|
|
|
ENABLE_SIGNUP: ${AI_ENABLE_SIGNUP:-true}
|
|
|
|
|
ENABLE_RAG_WEB_SEARCH: ${AI_ENABLE_RAG_WEB_SEARCH:-true}
|
|
|
|
|
ENABLE_RAG_WEB_LOADER_SSL_VERIFICATION: ${AI_ENABLE_RAG_SSL_VERIFY:-true}
|
|
|
|
|
|
|
|
|
|
# RAG configuration
|
|
|
|
|
RAG_EMBEDDING_ENGINE: ${AI_RAG_EMBEDDING_ENGINE:-openai}
|
|
|
|
|
RAG_EMBEDDING_MODEL: ${AI_RAG_EMBEDDING_MODEL:-text-embedding-3-small}
|
|
|
|
|
VECTOR_DB: ${AI_VECTOR_DB:-pgvector}
|
|
|
|
|
|
2025-11-15 18:34:38 +01:00
|
|
|
# Email configuration (Mailpit SMTP relay)
|
|
|
|
|
SMTP_HOST: net_mailpit
|
|
|
|
|
SMTP_PORT: 1025
|
2025-11-08 22:34:46 +01:00
|
|
|
SMTP_FROM_EMAIL: ${EMAIL_FROM}
|
|
|
|
|
SMTP_USE_TLS: false
|
2025-11-15 18:34:38 +01:00
|
|
|
SMTP_USE_SSL: false
|
2025-11-08 22:34:46 +01:00
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
|
- ai_webui_data:/app/backend/data
|
2025-11-21 20:20:33 +01:00
|
|
|
- ./functions:/app/backend/data/functions:ro
|
2025-11-08 22:34:46 +01:00
|
|
|
depends_on:
|
2025-11-08 22:35:41 +01:00
|
|
|
- ai_postgres
|
2025-11-08 22:58:09 +01:00
|
|
|
- litellm
|
2025-11-08 22:34:46 +01:00
|
|
|
networks:
|
|
|
|
|
- compose_network
|
|
|
|
|
labels:
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.enable=${AI_TRAEFIK_ENABLED}"
|
2025-11-08 22:34:46 +01:00
|
|
|
# HTTP to HTTPS redirect
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-redirect-web-secure.redirectscheme.scheme=https"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-web.middlewares=${AI_COMPOSE_PROJECT_NAME}-redirect-web-secure"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-web.rule=Host(`${AI_TRAEFIK_HOST}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-web.entrypoints=web"
|
2025-11-08 22:34:46 +01:00
|
|
|
# HTTPS router
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-web-secure.rule=Host(`${AI_TRAEFIK_HOST}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-web-secure.tls.certresolver=resolver"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-web-secure.entrypoints=web-secure"
|
|
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-web-secure-compress.compress=true"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-web-secure.middlewares=${AI_COMPOSE_PROJECT_NAME}-web-secure-compress,security-headers@file"
|
2025-11-08 22:34:46 +01:00
|
|
|
# Service
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.services.${AI_COMPOSE_PROJECT_NAME}-web-secure.loadbalancer.server.port=8080"
|
|
|
|
|
- "traefik.docker.network=${NETWORK_NAME}"
|
2025-11-08 22:34:46 +01:00
|
|
|
# Watchtower
|
2025-11-26 22:54:10 +01:00
|
|
|
- "com.centurylinklabs.watchtower.enable=${WATCHTOWER_LABEL_ENABLE}"
|
2025-11-08 22:34:46 +01:00
|
|
|
|
2025-11-08 22:58:09 +01:00
|
|
|
# LiteLLM - Proxy to convert Anthropic API to OpenAI-compatible format
|
|
|
|
|
litellm:
|
|
|
|
|
image: ghcr.io/berriai/litellm:main-latest
|
|
|
|
|
container_name: ${AI_COMPOSE_PROJECT_NAME}_litellm
|
|
|
|
|
restart: unless-stopped
|
|
|
|
|
environment:
|
|
|
|
|
TZ: ${TIMEZONE:-Europe/Berlin}
|
|
|
|
|
ANTHROPIC_API_KEY: ${ANTHROPIC_API_KEY}
|
2025-11-09 18:25:57 +01:00
|
|
|
LITELLM_MASTER_KEY: ${AI_LITELLM_API_KEY}
|
2025-11-09 18:34:10 +01:00
|
|
|
DATABASE_URL: postgresql://${AI_DB_USER}:${AI_DB_PASSWORD}@ai_postgres:5432/litellm
|
2025-11-23 16:22:54 +01:00
|
|
|
GPU_VLLM_LLAMA_URL: ${GPU_VLLM_LLAMA_URL}
|
2025-11-25 06:40:36 +01:00
|
|
|
GPU_VLLM_EMBED_URL: ${GPU_VLLM_EMBED_URL}
|
2025-11-21 18:46:33 +01:00
|
|
|
# LITELLM_DROP_PARAMS: 'true' # DISABLED: Was breaking streaming
|
2025-11-26 22:54:10 +01:00
|
|
|
NO_DOCS: "true"
|
|
|
|
|
NO_REDOC: "true"
|
2025-11-16 16:03:19 +01:00
|
|
|
# Performance optimizations
|
2025-11-26 22:54:10 +01:00
|
|
|
LITELLM_LOG: "DEBUG" # Enable detailed logging for debugging streaming issues
|
|
|
|
|
LITELLM_MODE: "PRODUCTION" # Production mode for better performance
|
2025-11-08 22:58:09 +01:00
|
|
|
volumes:
|
2025-11-08 22:59:50 +01:00
|
|
|
- ./litellm-config.yaml:/app/litellm-config.yaml:ro
|
2025-11-12 16:38:57 +01:00
|
|
|
command:
|
|
|
|
|
[
|
2025-11-26 22:54:10 +01:00
|
|
|
"--config",
|
|
|
|
|
"/app/litellm-config.yaml",
|
|
|
|
|
"--host",
|
|
|
|
|
"0.0.0.0",
|
|
|
|
|
"--port",
|
|
|
|
|
"4000",
|
2025-11-12 16:38:57 +01:00
|
|
|
]
|
2025-11-09 18:34:10 +01:00
|
|
|
depends_on:
|
|
|
|
|
- ai_postgres
|
2025-11-08 22:58:09 +01:00
|
|
|
networks:
|
|
|
|
|
- compose_network
|
|
|
|
|
healthcheck:
|
2025-11-09 18:13:26 +01:00
|
|
|
disable: true
|
2025-11-08 22:58:09 +01:00
|
|
|
labels:
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.enable=${AI_TRAEFIK_ENABLED}"
|
2025-11-09 17:56:34 +01:00
|
|
|
# HTTP to HTTPS redirect
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-litellm-redirect-web-secure.redirectscheme.scheme=https"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-litellm-web.middlewares=${AI_COMPOSE_PROJECT_NAME}-litellm-redirect-web-secure"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-litellm-web.rule=Host(`${AI_LITELLM_TRAEFIK_HOST}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-litellm-web.entrypoints=web"
|
2025-11-09 17:56:34 +01:00
|
|
|
# HTTPS router
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-litellm-web-secure.rule=Host(`${AI_LITELLM_TRAEFIK_HOST}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-litellm-web-secure.tls.certresolver=resolver"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-litellm-web-secure.entrypoints=web-secure"
|
|
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-litellm-web-secure-compress.compress=true"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-litellm-web-secure.middlewares=${AI_COMPOSE_PROJECT_NAME}-litellm-web-secure-compress,security-headers@file"
|
2025-11-09 17:56:34 +01:00
|
|
|
# Service
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.services.${AI_COMPOSE_PROJECT_NAME}-litellm-web-secure.loadbalancer.server.port=4000"
|
|
|
|
|
- "traefik.docker.network=${NETWORK_NAME}"
|
2025-11-08 22:58:09 +01:00
|
|
|
# Watchtower
|
2025-11-26 22:54:10 +01:00
|
|
|
- "com.centurylinklabs.watchtower.enable=${WATCHTOWER_LABEL_ENABLE}"
|
2025-11-08 22:58:09 +01:00
|
|
|
|
2025-11-12 09:36:52 +01:00
|
|
|
# Facefusion - AI face swapping and enhancement
|
|
|
|
|
facefusion:
|
2025-11-13 06:05:42 +01:00
|
|
|
build:
|
|
|
|
|
context: .
|
|
|
|
|
dockerfile: Dockerfile
|
|
|
|
|
image: facefusion-patched:3.5.0-cpu
|
2025-11-12 09:36:52 +01:00
|
|
|
container_name: ${AI_COMPOSE_PROJECT_NAME}_facefusion
|
2025-11-13 05:52:13 +01:00
|
|
|
restart: unless-stopped
|
2025-11-13 06:18:58 +01:00
|
|
|
tty: true
|
2025-11-26 22:54:10 +01:00
|
|
|
command: ["python", "-u", "facefusion.py", "run"]
|
2025-11-12 09:36:52 +01:00
|
|
|
environment:
|
|
|
|
|
TZ: ${TIMEZONE:-Europe/Berlin}
|
2025-11-13 05:52:13 +01:00
|
|
|
GRADIO_SERVER_NAME: "0.0.0.0"
|
|
|
|
|
GRADIO_SERVER_PORT: "7860"
|
2025-11-12 09:36:52 +01:00
|
|
|
volumes:
|
|
|
|
|
- ai_facefusion_data:/workspace
|
|
|
|
|
networks:
|
|
|
|
|
- compose_network
|
|
|
|
|
labels:
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.enable=${AI_FACEFUSION_TRAEFIK_ENABLED}"
|
2025-11-12 09:36:52 +01:00
|
|
|
# HTTP to HTTPS redirect
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-facefusion-redirect-web-secure.redirectscheme.scheme=https"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-facefusion-web.middlewares=${AI_COMPOSE_PROJECT_NAME}-facefusion-redirect-web-secure"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-facefusion-web.rule=Host(`${AI_FACEFUSION_TRAEFIK_HOST}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-facefusion-web.entrypoints=web"
|
2025-11-15 21:54:27 +01:00
|
|
|
# HTTPS router with Authelia
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-facefusion-web-secure.rule=Host(`${AI_FACEFUSION_TRAEFIK_HOST}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-facefusion-web-secure.tls.certresolver=resolver"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-facefusion-web-secure.entrypoints=web-secure"
|
|
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-facefusion-web-secure-compress.compress=true"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-facefusion-web-secure.middlewares=${AI_COMPOSE_PROJECT_NAME}-facefusion-web-secure-compress,net-authelia,security-headers@file"
|
2025-11-12 09:36:52 +01:00
|
|
|
# Service
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.services.${AI_COMPOSE_PROJECT_NAME}-facefusion-web-secure.loadbalancer.server.port=7860"
|
|
|
|
|
- "traefik.docker.network=${NETWORK_NAME}"
|
2025-11-13 08:30:51 +01:00
|
|
|
# Watchtower - disabled for custom local image
|
2025-11-26 22:54:10 +01:00
|
|
|
- "com.centurylinklabs.watchtower.enable=false"
|
2025-11-12 09:36:52 +01:00
|
|
|
|
2025-11-21 20:56:20 +01:00
|
|
|
# ComfyUI - Node-based UI for Flux image generation (proxies to RunPod GPU)
|
|
|
|
|
comfyui:
|
|
|
|
|
image: nginx:alpine
|
|
|
|
|
container_name: ${AI_COMPOSE_PROJECT_NAME}_comfyui
|
|
|
|
|
restart: unless-stopped
|
|
|
|
|
environment:
|
|
|
|
|
TZ: ${TIMEZONE:-Europe/Berlin}
|
2025-11-26 22:54:10 +01:00
|
|
|
GPU_SERVICE_HOST: ${GPU_TAILSCALE_HOST}
|
|
|
|
|
GPU_SERVICE_PORT: ${COMFYUI_BACKEND_PORT:-8188}
|
2025-11-21 20:56:20 +01:00
|
|
|
volumes:
|
2025-11-26 22:54:10 +01:00
|
|
|
- ./nginx.conf.template:/etc/nginx/nginx.conf.template:ro
|
|
|
|
|
command: /bin/sh -c "envsubst '$${GPU_SERVICE_HOST},$${GPU_SERVICE_PORT}' < /etc/nginx/nginx.conf.template > /etc/nginx/nginx.conf && exec nginx -g 'daemon off;'"
|
2025-11-21 20:56:20 +01:00
|
|
|
networks:
|
|
|
|
|
- compose_network
|
|
|
|
|
labels:
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.enable=${AI_COMFYUI_TRAEFIK_ENABLED:-true}"
|
2025-11-21 20:56:20 +01:00
|
|
|
# HTTP to HTTPS redirect
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-comfyui-redirect-web-secure.redirectscheme.scheme=https"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-comfyui-web.middlewares=${AI_COMPOSE_PROJECT_NAME}-comfyui-redirect-web-secure"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-comfyui-web.rule=Host(`${AI_COMFYUI_TRAEFIK_HOST:-comfy.ai.pivoine.art}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-comfyui-web.entrypoints=web"
|
2025-11-21 20:56:20 +01:00
|
|
|
# HTTPS router with Authelia SSO
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-comfyui-web-secure.rule=Host(`${AI_COMFYUI_TRAEFIK_HOST:-comfy.ai.pivoine.art}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-comfyui-web-secure.tls.certresolver=resolver"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-comfyui-web-secure.entrypoints=web-secure"
|
|
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-comfyui-web-secure-compress.compress=true"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-comfyui-web-secure.middlewares=${AI_COMPOSE_PROJECT_NAME}-comfyui-web-secure-compress,net-authelia,security-headers@file"
|
2025-11-21 20:56:20 +01:00
|
|
|
# Service
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.services.${AI_COMPOSE_PROJECT_NAME}-comfyui-web-secure.loadbalancer.server.port=80"
|
|
|
|
|
- "traefik.docker.network=${NETWORK_NAME}"
|
2025-11-21 20:56:20 +01:00
|
|
|
# Watchtower
|
2025-11-26 22:54:10 +01:00
|
|
|
- "com.centurylinklabs.watchtower.enable=${WATCHTOWER_LABEL_ENABLE}"
|
|
|
|
|
|
|
|
|
|
audiocraft:
|
|
|
|
|
image: nginx:alpine
|
|
|
|
|
container_name: ${AI_COMPOSE_PROJECT_NAME}_audiocraft
|
|
|
|
|
restart: unless-stopped
|
|
|
|
|
environment:
|
|
|
|
|
TZ: ${TIMEZONE:-Europe/Berlin}
|
|
|
|
|
GPU_SERVICE_HOST: ${GPU_TAILSCALE_HOST}
|
|
|
|
|
GPU_SERVICE_PORT: ${AUDIOCRAFT_BACKEND_PORT:-7860}
|
|
|
|
|
volumes:
|
|
|
|
|
- ./nginx.conf.template:/etc/nginx/nginx.conf.template:ro
|
|
|
|
|
command: /bin/sh -c "envsubst '$${GPU_SERVICE_HOST},$${GPU_SERVICE_PORT}' < /etc/nginx/nginx.conf.template > /etc/nginx/nginx.conf && exec nginx -g 'daemon off;'"
|
|
|
|
|
networks:
|
|
|
|
|
- compose_network
|
|
|
|
|
labels:
|
|
|
|
|
- "traefik.enable=${AI_AUDIOCRAFT_TRAEFIK_ENABLED:-true}"
|
|
|
|
|
# HTTP to HTTPS redirect
|
|
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-audiocraft-redirect-web-secure.redirectscheme.scheme=https"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web.middlewares=${AI_COMPOSE_PROJECT_NAME}-audiocraft-redirect-web-secure"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web.rule=Host(`${AI_AUDIOCRAFT_TRAEFIK_HOST:-audiocraft.ai.pivoine.art}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web.entrypoints=web"
|
|
|
|
|
# HTTPS router with Authelia SSO
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web-secure.rule=Host(`${AI_AUDIOCRAFT_TRAEFIK_HOST:-audiocraft.ai.pivoine.art}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web-secure.tls.certresolver=resolver"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web-secure.entrypoints=web-secure"
|
|
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web-secure-compress.compress=true"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web-secure.middlewares=${AI_COMPOSE_PROJECT_NAME}-audiocraft-web-secure-compress,net-authelia,security-headers@file"
|
|
|
|
|
# Service
|
|
|
|
|
- "traefik.http.services.${AI_COMPOSE_PROJECT_NAME}-audiocraft-web-secure.loadbalancer.server.port=80"
|
|
|
|
|
- "traefik.docker.network=${NETWORK_NAME}"
|
|
|
|
|
# Watchtower
|
|
|
|
|
- "com.centurylinklabs.watchtower.enable=${WATCHTOWER_LABEL_ENABLE}"
|
2025-11-21 20:56:20 +01:00
|
|
|
|
2025-11-23 20:18:29 +01:00
|
|
|
# Supervisor UI - Modern web interface for RunPod process management
|
2025-11-26 22:54:10 +01:00
|
|
|
supervisor:
|
2025-11-23 20:18:29 +01:00
|
|
|
image: dev.pivoine.art/valknar/supervisor-ui:latest
|
|
|
|
|
container_name: ${AI_COMPOSE_PROJECT_NAME}_supervisor_ui
|
2025-11-22 13:19:02 +01:00
|
|
|
restart: unless-stopped
|
|
|
|
|
environment:
|
|
|
|
|
TZ: ${TIMEZONE:-Europe/Berlin}
|
2025-11-23 20:18:29 +01:00
|
|
|
NODE_ENV: production
|
|
|
|
|
# Connect to RunPod Supervisor via Tailscale
|
2025-11-26 22:58:16 +01:00
|
|
|
SUPERVISOR_HOST: ${GPU_TAILSCALE_HOST}
|
2025-11-23 20:18:29 +01:00
|
|
|
SUPERVISOR_PORT: ${SUPERVISOR_BACKEND_PORT:-9001}
|
|
|
|
|
# No auth needed - Supervisor has auth disabled (protected by Authelia)
|
2025-11-22 13:19:02 +01:00
|
|
|
networks:
|
|
|
|
|
- compose_network
|
|
|
|
|
labels:
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.enable=${AI_SUPERVISOR_TRAEFIK_ENABLED:-true}"
|
2025-11-22 13:19:02 +01:00
|
|
|
# HTTP to HTTPS redirect
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-supervisor-redirect-web-secure.redirectscheme.scheme=https"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-supervisor-web.middlewares=${AI_COMPOSE_PROJECT_NAME}-supervisor-redirect-web-secure"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-supervisor-web.rule=Host(`${AI_SUPERVISOR_TRAEFIK_HOST:-supervisor.ai.pivoine.art}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-supervisor-web.entrypoints=web"
|
2025-11-22 13:19:02 +01:00
|
|
|
# HTTPS router with Authelia SSO
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-supervisor-web-secure.rule=Host(`${AI_SUPERVISOR_TRAEFIK_HOST:-supervisor.ai.pivoine.art}`)"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-supervisor-web-secure.tls.certresolver=resolver"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-supervisor-web-secure.entrypoints=web-secure"
|
|
|
|
|
- "traefik.http.middlewares.${AI_COMPOSE_PROJECT_NAME}-supervisor-web-secure-compress.compress=true"
|
|
|
|
|
- "traefik.http.routers.${AI_COMPOSE_PROJECT_NAME}-supervisor-web-secure.middlewares=${AI_COMPOSE_PROJECT_NAME}-supervisor-web-secure-compress,net-authelia,security-headers@file"
|
2025-11-23 20:18:29 +01:00
|
|
|
# Service (port 3000 for Next.js app)
|
2025-11-26 22:54:10 +01:00
|
|
|
- "traefik.http.services.${AI_COMPOSE_PROJECT_NAME}-supervisor-web-secure.loadbalancer.server.port=3000"
|
|
|
|
|
- "traefik.docker.network=${NETWORK_NAME}"
|
2025-11-22 13:19:02 +01:00
|
|
|
# Watchtower
|
2025-11-26 22:54:10 +01:00
|
|
|
- "com.centurylinklabs.watchtower.enable=${WATCHTOWER_LABEL_ENABLE}"
|
2025-11-22 13:19:02 +01:00
|
|
|
|
2025-11-08 22:34:46 +01:00
|
|
|
volumes:
|
|
|
|
|
ai_postgres_data:
|
|
|
|
|
name: ${AI_COMPOSE_PROJECT_NAME}_postgres_data
|
|
|
|
|
ai_webui_data:
|
|
|
|
|
name: ${AI_COMPOSE_PROJECT_NAME}_webui_data
|
2025-11-12 09:36:52 +01:00
|
|
|
ai_facefusion_data:
|
|
|
|
|
name: ${AI_COMPOSE_PROJECT_NAME}_facefusion_data
|