Files
zebra-power/docker-compose.yml

46 lines
922 B
YAML

# Docker Compose for Zebra Power
services:
backend:
build:
context: ./backend
dockerfile: Dockerfile
container_name: zebra_backend
ports:
- "8000:8000"
volumes:
- ./data:/app/data
environment:
- DATABASE_URL=sqlite:///data/zebra.db
- CORS_ORIGINS=http://localhost:3000,http://localhost
restart: unless-stopped
# Required for WOL packets
network_mode: host
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
container_name: zebra_frontend
ports:
- "3000:3000"
environment:
- VITE_API_URL=http://localhost:8000/api
depends_on:
- backend
restart: unless-stopped
nginx:
build:
context: ./nginx
dockerfile: Dockerfile
container_name: zebra_nginx
ports:
- "80:80"
depends_on:
- frontend
- backend
restart: unless-stopped
volumes:
data: