generated from rolling-scopes-school/nodejs-course-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
48 lines (48 loc) · 1 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
version: '3.7'
services:
node:
build: .
image: trello:ts-rest
ports:
- ${PORT}:${PORT}
depends_on:
- postgres
# entrypoint: ["./entrypoint.sh"]
environment:
- PORT=${PORT}
- JWT_SECRET_KEY=${JWT_SECRET_KEY}
env_file:
- .env
volumes:
- logs:/usr/app/logs
- ./src:/usr/app/src
- ./uploads:/usr/app/uploads
restart: always
networks:
- back
postgres:
build: ./database/
image: trello:postgres
ports:
- ${POSTGRES_PORT}:${POSTGRES_PORT}
# command: -p ${POSTGRES_PORT}
environment:
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
- POSTGRES_DB=${POSTGRES_DB}
- PGPORT=${POSTGRES_PORT}
volumes:
- database:/var/lib/postgresql/data
restart: always
networks:
- back
volumes:
logs:
database:
networks:
back:
driver: bridge
ipam:
config:
- subnet: 172.16.238.0/24
gateway: 172.16.238.1