-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
57 lines (57 loc) · 1.23 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
54
55
56
57
services:
db:
image: postgres:16-alpine
restart: always
ports:
- "5432:5432"
environment:
- POSTGRES_PASSWORD=postgres
volumes:
- ./docker/db/sql:/docker-entrypoint-initdb.d
- pg-data:/var/lib/postgresql/data
pgadmin:
image: dpage/pgadmin4:latest
environment:
- PGADMIN_DEFAULT_EMAIL=root@db.com
- PGADMIN_DEFAULT_PASSWORD=root
restart: always
ports:
- "5000:80"
volumes:
- pgadmin-data:/var/lib/pgadmin
- ./docker/pgadmin/servers.json:/pgadmin4/servers.json
depends_on:
- "db"
service:
profiles: ["all", "service", "test"]
build:
context: ./service
restart: always
user: "${UID}"
ports:
- "3000:3000"
depends_on:
- "db"
volumes:
- ./service:/service
- /dev/null:/service/.env
- node-data:/home/node
command: ash -c 'npm install && npm start'
app:
profiles: ["all", "app", "test"]
build:
context: ./app
restart: always
user: "${UID}"
ports:
- "3001:3000"
depends_on:
- "service"
volumes:
- ./app:/app
- node-data:/home/node
command: node /app/.output/server/index.mjs
volumes:
pg-data:
pgadmin-data:
node-data: