-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
56 lines (55 loc) · 1.21 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
version: '3.9'
services:
frontend:
container_name: ng_frontend
working_dir: /web
build: ./web
ports:
- 3000:3000
restart: always
depends_on:
backend:
condition: service_healthy
networks:
- rede-virtual-1
backend:
container_name: ng_backend
working_dir: /app-backend
build: ./server
ports:
- 3001:3001
- 5555:5555
depends_on:
db:
condition: service_healthy
restart: always
volumes:
- ./server/src:/app-backend/src
- ./server/prisma:/app-backend/prisma
networks:
- rede-virtual-1
- rede-virtual-2
healthcheck:
test: ["CMD", "lsof", "-t", "-i:3001"]
timeout: 10s
retries: 5
environment:
- JWT_SECRET=jwt_secret
- DB_PASS=password
- DATABASE_URL=postgresql://postgres:password@db:5432/ng-cash?schema=public
db:
container_name: db_postgres
image: postgres:13.2
ports:
- 5432:5432
environment:
- POSTGRES_PASSWORD=password
- POSTGRES_USER=postgres
restart: always
volumes:
- ./server/database:/var/lib/postgresql/data
networks:
- rede-virtual-2
networks:
rede-virtual-1:
rede-virtual-2: