app/docker-compose.yml

46 lines
1 KiB
YAML
Raw Normal View History

2025-04-15 21:56:28 +02:00
version: "3.8"
2025-01-19 18:31:05 +01:00
services:
2025-04-15 21:56:28 +02:00
db:
image: mysql:8.0
container_name: dishplanner-db
restart: unless-stopped
environment:
MYSQL_ROOT_PASSWORD: rootpassword
MYSQL_DATABASE: dishplanner
MYSQL_USER: dishuser
MYSQL_PASSWORD: dishpass
2025-01-19 18:31:05 +01:00
volumes:
2025-04-15 21:56:28 +02:00
- db_data:/var/lib/mysql
backend:
image: jochent/dishplanner-backend:latest
container_name: dishplanner-backend
restart: unless-stopped
2025-01-19 18:31:05 +01:00
environment:
2025-04-15 21:56:28 +02:00
DB_CONNECTION: mysql
DB_HOST: db
DB_PORT: 3306
DB_DATABASE: dishplanner
DB_USERNAME: dishuser
DB_PASSWORD: dishpass
2025-01-19 18:31:05 +01:00
depends_on:
- db
2025-04-15 21:56:28 +02:00
ports:
- "9000:9000" # Only needed if exposing php-fpm, otherwise remove
2025-01-19 18:31:05 +01:00
frontend:
2025-04-15 21:56:28 +02:00
image: jochent/dishplanner-frontend:latest
container_name: dishplanner-frontend
restart: unless-stopped
2025-01-19 18:31:05 +01:00
environment:
2025-04-15 21:56:28 +02:00
NEXT_PUBLIC_API_URL: http://localhost:9000 # or backend:9000 if hitting directly
2025-01-19 18:31:05 +01:00
depends_on:
- backend
2025-04-15 21:56:28 +02:00
ports:
- "3000:3000"
2025-01-19 18:31:05 +01:00
volumes:
2025-04-15 21:56:28 +02:00
db_data: