101 lines
2.6 KiB
YAML
101 lines
2.6 KiB
YAML
services:
|
|
caption-local:
|
|
build:
|
|
context: ./caption-local
|
|
dockerfile: Dockerfile
|
|
ports:
|
|
- "127.0.0.1:8765:8765"
|
|
volumes:
|
|
- caption-local-cache:/models
|
|
- caption-local-keys:/data
|
|
env_file:
|
|
- path: ./secrets/caption-local.env
|
|
required: false
|
|
environment:
|
|
- PYTHONUNBUFFERED=1
|
|
- CAPTION_ROOMS_DB=/data/rooms.db
|
|
- CAPTION_MODEL=${CAPTION_MODEL:-small}
|
|
- CAPTION_OFFLINE=${CAPTION_OFFLINE:-0}
|
|
- CAPTION_ALLOW_INSECURE_LAN=${CAPTION_ALLOW_INSECURE_LAN:-0}
|
|
- CAPTION_COOKIE_SECURE=${CAPTION_COOKIE_SECURE:-auto}
|
|
- RELAY_ADDRESS=${RELAY_ADDRESS:-ws://localhost:8080/ws}
|
|
- RELAY_SITE=${RELAY_SITE:-http://localhost:8080/}
|
|
networks:
|
|
- caption
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD", "python", "/app/healthcheck.py"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
start_period: 10s
|
|
retries: 3
|
|
|
|
captionninja-relay:
|
|
build:
|
|
context: ./captionninja/relay
|
|
dockerfile: Dockerfile
|
|
ports:
|
|
- "127.0.0.1:8787:8787"
|
|
environment:
|
|
- PORT=8787
|
|
- HOST=0.0.0.0
|
|
- CAPTION_RELAY_CONFIG=/run/relay.json
|
|
volumes:
|
|
- ${CAPTION_RELAY_CONFIG:-./secrets/relay.json}:/run/relay.json:ro
|
|
networks:
|
|
- caption
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD", "node", "-e", "fetch('http://127.0.0.1:8787/health').then(r => process.exit(r.ok ? 0 : 1)).catch(() => process.exit(1))"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
start_period: 10s
|
|
retries: 3
|
|
|
|
captionninja-web:
|
|
build:
|
|
context: .
|
|
dockerfile: web/Dockerfile
|
|
ports:
|
|
- "${CAPTION_WEB_BIND:-127.0.0.1}:8080:80"
|
|
environment:
|
|
- RELAY_URL=${RELAY_URL:-ws://localhost:8080/ws}
|
|
- CAPTURE_URL=${CAPTURE_URL:-http://localhost:8080/capture-local.html}
|
|
- TRANSLATION_MODELS=${TRANSLATION_MODELS:-all}
|
|
volumes:
|
|
- translation-models:/usr/share/nginx/models
|
|
networks:
|
|
- caption
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD", "wget", "-qO-", "http://127.0.0.1"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
start_period: 10s
|
|
retries: 3
|
|
|
|
wiki:
|
|
build:
|
|
context: .
|
|
dockerfile: wiki/Dockerfile
|
|
ports:
|
|
- "${WIKI_BIND:-127.0.0.1}:8081:80"
|
|
networks:
|
|
- caption
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD", "wget", "-qO-", "http://127.0.0.1"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
start_period: 10s
|
|
retries: 3
|
|
|
|
volumes:
|
|
caption-local-cache:
|
|
caption-local-keys:
|
|
translation-models:
|
|
|
|
networks:
|
|
caption:
|
|
driver: bridge
|