polishing for prod testing.
This commit is contained in:
+24
-22
@@ -1,24 +1,30 @@
|
||||
# GallerySubscriber - Production Docker Compose
|
||||
#
|
||||
# Quick Start:
|
||||
# 1. Copy .env.example to .env and configure required values
|
||||
# 2. Run: docker compose up -d
|
||||
# 3. Access the web UI at http://localhost:8080
|
||||
#
|
||||
# For development, see docker-compose.dev.yml
|
||||
|
||||
services:
|
||||
# Combined backend API + frontend static files
|
||||
app:
|
||||
build: .
|
||||
image: git.fabledsword.com/bvandeusen/gallerysubscriber:latest
|
||||
ports:
|
||||
- "${PORT:-8080}:8080"
|
||||
environment:
|
||||
- TZ=${TZ:-America/New_York}
|
||||
- DATABASE_URL=postgresql://gdl:${DB_PASSWORD}@db:5432/gallery_subscriber
|
||||
- REDIS_URL=redis://redis:6379/0
|
||||
- DATABASE_URL=postgresql://${DB_USER:-gdl}:${DB_PASSWORD}@${DB_HOST:-db}:${DB_PORT:-5432}/${DB_NAME:-gallery_subscriber}
|
||||
- REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}/0
|
||||
- SECRET_KEY=${SECRET_KEY}
|
||||
- DOWNLOAD_PATH=/data/downloads
|
||||
- CONFIG_PATH=/data/config
|
||||
- COOKIES_PATH=/data/cookies
|
||||
- DOWNLOAD_PARALLEL_LIMIT=${DOWNLOAD_PARALLEL_LIMIT:-3}
|
||||
- DOWNLOAD_RATE_LIMIT=${DOWNLOAD_RATE_LIMIT:-3.0}
|
||||
- DEFAULT_CHECK_INTERVAL=${DEFAULT_CHECK_INTERVAL:-3600}
|
||||
- LOG_LEVEL=${LOG_LEVEL:-INFO}
|
||||
volumes:
|
||||
- downloads:/data/downloads
|
||||
- config:/data/config
|
||||
- cookies:/data/cookies
|
||||
- ${DATA_DOWNLOADS:-downloads}:/data/downloads
|
||||
- ${DATA_CONFIG:-config}:/data/config
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_healthy
|
||||
@@ -28,23 +34,20 @@ services:
|
||||
|
||||
# Celery worker for background tasks
|
||||
celery:
|
||||
build: .
|
||||
image: git.fabledsword.com/bvandeusen/gallerysubscriber:latest
|
||||
command: celery -A app.tasks.celery_app worker -B --loglevel=info
|
||||
environment:
|
||||
- TZ=${TZ:-America/New_York}
|
||||
- DATABASE_URL=postgresql://gdl:${DB_PASSWORD}@db:5432/gallery_subscriber
|
||||
- REDIS_URL=redis://redis:6379/0
|
||||
- DATABASE_URL=postgresql://${DB_USER:-gdl}:${DB_PASSWORD}@${DB_HOST:-db}:${DB_PORT:-5432}/${DB_NAME:-gallery_subscriber}
|
||||
- REDIS_URL=redis://${REDIS_HOST:-redis}:${REDIS_PORT:-6379}/0
|
||||
- SECRET_KEY=${SECRET_KEY}
|
||||
- DOWNLOAD_PATH=/data/downloads
|
||||
- CONFIG_PATH=/data/config
|
||||
- COOKIES_PATH=/data/cookies
|
||||
- DOWNLOAD_PARALLEL_LIMIT=${DOWNLOAD_PARALLEL_LIMIT:-3}
|
||||
- DOWNLOAD_RATE_LIMIT=${DOWNLOAD_RATE_LIMIT:-3.0}
|
||||
- DEFAULT_CHECK_INTERVAL=${DEFAULT_CHECK_INTERVAL:-3600}
|
||||
- LOG_LEVEL=${LOG_LEVEL:-INFO}
|
||||
volumes:
|
||||
- downloads:/data/downloads
|
||||
- config:/data/config
|
||||
- cookies:/data/cookies
|
||||
- ${DATA_DOWNLOADS:-downloads}:/data/downloads
|
||||
- ${DATA_CONFIG:-config}:/data/config
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_healthy
|
||||
@@ -57,13 +60,13 @@ services:
|
||||
image: postgres:15-alpine
|
||||
environment:
|
||||
- TZ=${TZ:-America/New_York}
|
||||
- POSTGRES_USER=gdl
|
||||
- POSTGRES_USER=${DB_USER:-gdl}
|
||||
- POSTGRES_PASSWORD=${DB_PASSWORD}
|
||||
- POSTGRES_DB=gallery_subscriber
|
||||
- POSTGRES_DB=${DB_NAME:-gallery_subscriber}
|
||||
volumes:
|
||||
- postgres_data:/var/lib/postgresql/data
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U gdl -d gallery_subscriber"]
|
||||
test: ["CMD-SHELL", "pg_isready -U ${DB_USER:-gdl} -d ${DB_NAME:-gallery_subscriber}"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
@@ -78,4 +81,3 @@ volumes:
|
||||
postgres_data:
|
||||
downloads:
|
||||
config:
|
||||
cookies:
|
||||
|
||||
Reference in New Issue
Block a user