-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
53 lines (51 loc) · 1.01 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
services:
api:
build:
context: "./server"
dockerfile: Dockerfile
env_file:
- .env
volumes:
- "./server:/usr/app"
- "/usr/app/node_modules"
ports:
- 4000:4000
- 9229:9229
depends_on:
- postgres
- redis
redis:
build:
context: "./redis"
dockerfile: Dockerfile
privileged: true
command: sh -c "./init.sh"
volumes:
- "redis:/data"
postgres:
image: postgres:latest
restart: always
environment:
POSTGRES_DB: ${PGDATABASE}
POSTGRES_USER: ${PGUSER}
POSTGRES_PASSWORD: ${PGPASSWORD}
PGDATA: "/var/lib/postgresql/data/pgdata"
POSTGRES_HOST_AUTH_METHOD:
ports:
- "5432:5432"
volumes:
- "postgres:/var/lib/postgresql/data/pgdata"
client:
build:
dockerfile: Dockerfile
context: "./client"
volumes:
- "./client:/usr/app"
- "/usr/app/node_modules"
ports:
- "5173:5173"
depends_on:
- api
volumes:
postgres:
redis: