-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
49 lines (44 loc) · 909 Bytes
/
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
version: '3.8'
services:
postgres:
image: postgres:15.3-alpine
# restart: always
environment:
POSTGRES_USER: ${DB_USERNAME}
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_DB: ${DB_NAME}
ports:
- "5433:5433"
volumes:
- postgres-data:/var/lib/postgresql/data
networks:
- app-network
api-service:
build:
context: ./api-service
ports:
- "${API_PORT}:${API_PORT}"
environment:
- NODE_ENV=development
- PORT=${API_PORT}
depends_on:
- postgres
- stock-service
networks:
- app-network
restart: always
stock-service:
build:
context: ./stock-service
ports:
- "${STOCK_PORT}:${STOCK_PORT}"
environment:
- NODE_ENV=development
- PORT=${STOCK_PORT}
networks:
- app-network
networks:
app-network:
driver: bridge
volumes:
postgres-data: