2020-03-05 18:23:28 +00:00
|
|
|
version: "3.7"
|
|
|
|
services:
|
|
|
|
backend:
|
|
|
|
build: backend
|
|
|
|
ports:
|
2020-03-23 23:36:46 +00:00
|
|
|
- 8080:8080
|
2020-03-12 13:16:55 +00:00
|
|
|
environment:
|
2020-03-23 23:36:46 +00:00
|
|
|
- POSTGRES_DB=example
|
2020-03-12 13:16:55 +00:00
|
|
|
networks:
|
2020-03-20 17:19:08 +00:00
|
|
|
- spring-postgres
|
2020-03-05 18:23:28 +00:00
|
|
|
db:
|
|
|
|
image: postgres
|
|
|
|
restart: always
|
|
|
|
secrets:
|
2020-03-23 23:36:46 +00:00
|
|
|
- db-password
|
2020-03-05 18:23:28 +00:00
|
|
|
volumes:
|
2020-03-23 23:36:46 +00:00
|
|
|
- db-data:/var/lib/postgresql/data
|
2020-03-12 13:16:55 +00:00
|
|
|
networks:
|
2020-03-20 17:19:08 +00:00
|
|
|
- spring-postgres
|
2020-03-23 23:36:46 +00:00
|
|
|
environment:
|
|
|
|
- POSTGRES_DB=example
|
|
|
|
- POSTGRES_PASSWORD_FILE=/run/secrets/db-password
|
2020-03-05 18:23:28 +00:00
|
|
|
volumes:
|
2020-03-23 23:36:46 +00:00
|
|
|
db-data:
|
2020-03-05 18:23:28 +00:00
|
|
|
secrets:
|
|
|
|
db-password:
|
|
|
|
file: db/password.txt
|
2020-03-12 13:16:55 +00:00
|
|
|
networks:
|
2020-03-23 23:36:46 +00:00
|
|
|
spring-postgres:
|