File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11services :
2+
23 db :
34 image : postgres:13-alpine
4- container_name : codebuilder-db
5- environment :
6- POSTGRES_USER : ${DB_USER:-nestjs}
7- POSTGRES_PASSWORD : ${DB_PASSWORD:-nestpass}
8- POSTGRES_DB : ${DB_NAME:-nestdb}
5+ container_name : codebuilder-postgres-db
6+ restart : unless-stopped
7+ env_file :
8+ - ./.env
99 volumes :
1010 - codebuilder-db-data:/var/lib/postgresql/data
1111 networks :
1212 - codebuilder-net
13+ ports :
14+ - " 5434:5432"
15+
1316
1417 api :
1518 build :
1619 context : .
1720 dockerfile : Dockerfile
1821 container_name : codebuilder-api
19- environment :
20- DB_HOST : db
21- DB_PORT : 5432
22- DB_USER : ${DB_USER:-nestjs}
23- DB_PASSWORD : ${DB_PASSWORD:-nestpass}
24- DB_NAME : ${DB_NAME:-nestdb}
25- PORT : 4000
22+ restart : unless-stopped
23+ env_file :
24+ - ./.env
2625 ports :
2726 - " 4000:4000"
2827 depends_on :
@@ -32,9 +31,11 @@ services:
3231 - codebuilder-net
3332
3433
34+
3535volumes :
3636 codebuilder-db-data :
3737
38+
3839networks :
3940 codebuilder-net :
4041 external : true
You can’t perform that action at this time.
0 commit comments