sendio/docker-compose.yml
2026-01-13 05:17:57 +02:00

70 lines
1.9 KiB
YAML

version: '3.8'
services:
postgres:
image: postgres:15
environment:
POSTGRES_DB: whatssender
POSTGRES_USER: whatssender
POSTGRES_PASSWORD: whatssender123
ports:
- "5433:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U whatssender"]
interval: 5s
timeout: 5s
retries: 5
backend:
build:
context: ./backend
dockerfile: Dockerfile
ports:
- "8000:8000"
environment:
DATABASE_URL: postgresql://whatssender:whatssender123@postgres:5432/whatssender
JWT_SECRET: your-secret-key-change-in-production
CORS_ORIGINS: http://localhost:3000,http://localhost:5173
GOOGLE_CLIENT_ID: your-google-client-id
GOOGLE_CLIENT_SECRET: your-google-client-secret
GOOGLE_REDIRECT_URI: http://localhost:8000/api/imports/google/callback
GOOGLE_TOKEN_ENCRYPTION_KEY: your-fernet-key-32-bytes-base64
WHATSAPP_PROVIDER: telegram
WHATSAPP_CLOUD_ACCESS_TOKEN: your-whatsapp-token
WHATSAPP_CLOUD_PHONE_NUMBER_ID: your-phone-number-id
WHATSAPP_WEBHOOK_VERIFY_TOKEN: your-webhook-verify-token
TELEGRAM_BOT_TOKEN: 8428015346:AAH2MOb9D1HUlINOxcDFMa6q98qGo4rPSYo
depends_on:
postgres:
condition: service_healthy
volumes:
- ./backend:/app
command: uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
ports:
- "5173:5173"
environment:
VITE_API_URL: http://localhost:8000
volumes:
- ./frontend:/app
- /app/node_modules
command: npm run dev -- --host
# Optional Redis for Celery (uncomment when ready to use)
# redis:
# image: redis:7-alpine
# ports:
# - "6379:6379"
# volumes:
# - redis_data:/data
volumes:
postgres_data:
# redis_data: