76 lines
2.0 KiB
YAML
76 lines
2.0 KiB
YAML
services:
|
|
postgres:
|
|
image: postgres:16-alpine
|
|
environment:
|
|
POSTGRES_USER: reseller
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
|
POSTGRES_DB: reseller
|
|
volumes:
|
|
- pgdata:/var/lib/postgresql/data
|
|
- ./db/schema.sql:/docker-entrypoint-initdb.d/01-schema.sql:ro
|
|
ports:
|
|
- "5432:5432"
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U reseller"]
|
|
interval: 5s
|
|
timeout: 3s
|
|
retries: 10
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
ports:
|
|
- "6379:6379"
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 5s
|
|
timeout: 3s
|
|
retries: 10
|
|
|
|
api:
|
|
build: ./backend
|
|
environment:
|
|
DATABASE_URL: postgresql+psycopg2://reseller:${POSTGRES_PASSWORD}@postgres:5432/reseller
|
|
REDIS_URL: redis://redis:6379/0
|
|
SECRET_KEY: ${SECRET_KEY:-polaris-dev-secret-change-me}
|
|
ADMIN_EMAIL: ${ADMIN_EMAIL:-admin@polaris.local}
|
|
ADMIN_PASSWORD: ${ADMIN_PASSWORD:-changeme}
|
|
BTCPAY_URL: https://10.30.20.140
|
|
BTCPAY_KEY: ${BTCPAY_KEY}
|
|
BTCPAY_STORE_ID: 3KJ1r5HK9MAiD5xvBapkv1iTHU1Ro9MdBc4XuPivQsev
|
|
BTCPAY_WEBHOOK_SECRET: polaris_btcpay_wh_9f3k2m8v7x
|
|
PRINTFUL_API_KEY: ${PRINTFUL_API_KEY:-}
|
|
STOREFRONT_URL: https://polaris.thetempleofdoom.com
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
redis:
|
|
condition: service_healthy
|
|
expose:
|
|
- "8000"
|
|
restart: unless-stopped
|
|
|
|
worker:
|
|
build: ./backend
|
|
command: celery -A app.tasks.celery_app worker --loglevel=info -B
|
|
environment:
|
|
DATABASE_URL: postgresql+psycopg2://reseller:${POSTGRES_PASSWORD}@postgres:5432/reseller
|
|
REDIS_URL: redis://redis:6379/0
|
|
SECRET_KEY: ${SECRET_KEY:-polaris-dev-secret-change-me}
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
redis:
|
|
condition: service_healthy
|
|
restart: unless-stopped
|
|
|
|
frontend:
|
|
build: ./frontend
|
|
ports:
|
|
- "80:80"
|
|
depends_on:
|
|
- api
|
|
restart: unless-stopped
|
|
|
|
volumes:
|
|
pgdata:
|