47 lines
819 B
YAML
47 lines
819 B
YAML
version: '3.8'
|
|
|
|
services:
|
|
frontend:
|
|
build:
|
|
context: ./client
|
|
dockerfile: Dockerfile
|
|
environment:
|
|
- PORT=4000
|
|
depends_on:
|
|
- backend
|
|
|
|
backend:
|
|
build:
|
|
context: ./api
|
|
dockerfile: Dockerfile
|
|
environment:
|
|
- PORT=4001
|
|
- PGHOST=postgres
|
|
- PGPORT=5432
|
|
- PGUSER=postgres
|
|
- PGPASSWORD=postgres
|
|
- PGDATABASE=ckqr
|
|
- REDIS_HOST=redis
|
|
- REDIS_PORT=6379
|
|
depends_on:
|
|
- postgres
|
|
- redis
|
|
|
|
postgres:
|
|
image: postgres:15-alpine
|
|
environment:
|
|
- POSTGRES_USER=postgres
|
|
- POSTGRES_PASSWORD=postgres
|
|
- POSTGRES_DB=ckqr
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
volumes:
|
|
- redis_data:/data
|
|
|
|
volumes:
|
|
postgres_data:
|
|
redis_data:
|