Synology ACL이 username 기반 chown을 거부하고 컨테이너 내부에 bgg8988 사용자가 없어 매 배포마다 WARN 로그가 쏟아지던 문제 해결. - PUID/PGID 환경변수를 deployer 컨테이너에 전달 - find로 소유자가 다른 항목만 골라 numeric chown (idempotent) - 실패는 silent — 어차피 파일 기능엔 영향 없음 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
215 lines
7.0 KiB
YAML
215 lines
7.0 KiB
YAML
name: webpage
|
|
|
|
services:
|
|
backend:
|
|
build:
|
|
context: ./backend
|
|
args:
|
|
APP_VERSION: ${APP_VERSION:-dev}
|
|
container_name: lotto-backend
|
|
restart: unless-stopped
|
|
ports:
|
|
- "18000:8000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- LOTTO_ALL_URL=${LOTTO_ALL_URL:-https://smok95.github.io/lotto/results/all.json}
|
|
- LOTTO_LATEST_URL=${LOTTO_LATEST_URL:-https://smok95.github.io/lotto/results/latest.json}
|
|
volumes:
|
|
- ${RUNTIME_PATH}/data:/app/data
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
stock-lab:
|
|
build:
|
|
context: ./stock-lab
|
|
args:
|
|
APP_VERSION: ${APP_VERSION:-dev}
|
|
container_name: stock-lab
|
|
restart: unless-stopped
|
|
ports:
|
|
- "18500:8000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- WINDOWS_AI_SERVER_URL=${WINDOWS_AI_SERVER_URL:-http://192.168.0.5:8000}
|
|
- GEMINI_API_KEY=${GEMINI_API_KEY:-}
|
|
- GEMINI_MODEL=${GEMINI_MODEL:-gemini-1.5-flash}
|
|
- ADMIN_API_KEY=${ADMIN_API_KEY:-}
|
|
- ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY:-}
|
|
- ANTHROPIC_MODEL=${ANTHROPIC_MODEL:-claude-haiku-4-5-20251001}
|
|
- LLM_PROVIDER=${LLM_PROVIDER:-claude}
|
|
- OLLAMA_URL=${OLLAMA_URL:-http://192.168.45.59:11435}
|
|
- OLLAMA_MODEL=${OLLAMA_MODEL:-qwen3:14b}
|
|
- CORS_ALLOW_ORIGINS=${CORS_ALLOW_ORIGINS:-http://localhost:3007,http://localhost:8080}
|
|
volumes:
|
|
- ${RUNTIME_PATH}/data/stock:/app/data
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
music-lab:
|
|
build:
|
|
context: ./music-lab
|
|
container_name: music-lab
|
|
restart: unless-stopped
|
|
ports:
|
|
- "18600:8000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- MUSIC_AI_SERVER_URL=${MUSIC_AI_SERVER_URL:-}
|
|
- SUNO_API_KEY=${SUNO_API_KEY:-}
|
|
- MUSIC_MEDIA_BASE=${MUSIC_MEDIA_BASE:-/media/music}
|
|
- CORS_ALLOW_ORIGINS=${CORS_ALLOW_ORIGINS:-http://localhost:3007,http://localhost:8080}
|
|
volumes:
|
|
- ${RUNTIME_PATH}/data/music:/app/data
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
blog-lab:
|
|
build:
|
|
context: ./blog-lab
|
|
container_name: blog-lab
|
|
restart: unless-stopped
|
|
ports:
|
|
- "18700:8000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY:-}
|
|
- NAVER_CLIENT_ID=${NAVER_CLIENT_ID:-}
|
|
- NAVER_CLIENT_SECRET=${NAVER_CLIENT_SECRET:-}
|
|
- CORS_ALLOW_ORIGINS=${CORS_ALLOW_ORIGINS:-http://localhost:3007,http://localhost:8080}
|
|
volumes:
|
|
- ${RUNTIME_PATH}/data/blog:/app/data
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
realestate-lab:
|
|
build:
|
|
context: ./realestate-lab
|
|
container_name: realestate-lab
|
|
restart: unless-stopped
|
|
ports:
|
|
- "18800:8000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- DATA_GO_KR_API_KEY=${DATA_GO_KR_API_KEY:-}
|
|
- CORS_ALLOW_ORIGINS=${CORS_ALLOW_ORIGINS:-http://localhost:3007,http://localhost:8080}
|
|
volumes:
|
|
- ${RUNTIME_PATH}/data/realestate:/app/data
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
agent-office:
|
|
build:
|
|
context: ./agent-office
|
|
container_name: agent-office
|
|
restart: unless-stopped
|
|
ports:
|
|
- "18900:8000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- CORS_ALLOW_ORIGINS=${CORS_ALLOW_ORIGINS:-http://localhost:3007,http://localhost:8080}
|
|
- STOCK_LAB_URL=http://stock-lab:8000
|
|
- MUSIC_LAB_URL=http://music-lab:8000
|
|
- BLOG_LAB_URL=http://blog-lab:8000
|
|
- REALESTATE_LAB_URL=http://realestate-lab:8000
|
|
- TELEGRAM_BOT_TOKEN=${TELEGRAM_BOT_TOKEN:-}
|
|
- TELEGRAM_CHAT_ID=${TELEGRAM_CHAT_ID:-}
|
|
- TELEGRAM_WEBHOOK_URL=${TELEGRAM_WEBHOOK_URL:-}
|
|
- TELEGRAM_WIFE_CHAT_ID=${TELEGRAM_WIFE_CHAT_ID:-}
|
|
- ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY:-}
|
|
- LOTTO_BACKEND_URL=${LOTTO_BACKEND_URL:-http://lotto-backend:8000}
|
|
- LOTTO_CURATOR_MODEL=${LOTTO_CURATOR_MODEL:-claude-sonnet-4-5}
|
|
- CONVERSATION_MODEL=${CONVERSATION_MODEL:-claude-haiku-4-5-20251001}
|
|
- CONVERSATION_HISTORY_LIMIT=${CONVERSATION_HISTORY_LIMIT:-20}
|
|
- CONVERSATION_RATE_PER_MIN=${CONVERSATION_RATE_PER_MIN:-6}
|
|
volumes:
|
|
- ${RUNTIME_PATH:-.}/data/agent-office:/app/data
|
|
depends_on:
|
|
- stock-lab
|
|
- music-lab
|
|
- blog-lab
|
|
- realestate-lab
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
travel-proxy:
|
|
build: ./travel-proxy
|
|
container_name: travel-proxy
|
|
restart: unless-stopped
|
|
user: "${PUID}:${PGID}"
|
|
ports:
|
|
- "19000:8000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- TRAVEL_ROOT=${TRAVEL_ROOT:-/data/travel}
|
|
- TRAVEL_THUMB_ROOT=${TRAVEL_THUMB_ROOT:-/data/thumbs}
|
|
- TRAVEL_MEDIA_BASE=${TRAVEL_MEDIA_BASE:-/media/travel}
|
|
- TRAVEL_CACHE_TTL=${TRAVEL_CACHE_TTL:-300}
|
|
- CORS_ALLOW_ORIGINS=${CORS_ALLOW_ORIGINS:-http://localhost:3007,http://localhost:8080}
|
|
volumes:
|
|
- ${PHOTO_PATH}:/data/travel:ro
|
|
- ${RUNTIME_PATH}/travel-thumbs:/data/thumbs:rw
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
frontend:
|
|
image: nginx:alpine
|
|
container_name: lotto-frontend
|
|
restart: unless-stopped
|
|
depends_on:
|
|
- music-lab
|
|
- blog-lab
|
|
- realestate-lab
|
|
ports:
|
|
- "8080:80"
|
|
volumes:
|
|
- ${FRONTEND_PATH}:/usr/share/nginx/html:ro
|
|
- ${RUNTIME_PATH}/nginx/default.conf:/etc/nginx/conf.d/default.conf:ro
|
|
- ${PHOTO_PATH}:/data/travel:ro
|
|
- ${RUNTIME_PATH}/travel-thumbs:/data/thumbs:ro
|
|
- ${RUNTIME_PATH}/data/music:/data/music:ro
|
|
extra_hosts:
|
|
- "host.docker.internal:host-gateway"
|
|
healthcheck:
|
|
test: ["CMD", "wget", "-q", "--spider", "http://localhost:80/"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
|
|
deployer:
|
|
build: ./deployer
|
|
container_name: webpage-deployer
|
|
restart: unless-stopped
|
|
ports:
|
|
- "127.0.0.1:19010:9000"
|
|
environment:
|
|
- TZ=${TZ:-Asia/Seoul}
|
|
- WEBHOOK_SECRET=${WEBHOOK_SECRET}
|
|
- PUID=${PUID:-1026}
|
|
- PGID=${PGID:-100}
|
|
volumes:
|
|
- ${REPO_PATH}:/repo:rw
|
|
- ${RUNTIME_PATH}:/runtime:rw
|
|
- ${RUNTIME_PATH}/scripts:/scripts:ro
|
|
- /var/run/docker.sock:/var/run/docker.sock
|