-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
47 lines (45 loc) · 1.21 KB
/
Copy pathdocker-compose.yml
File metadata and controls
47 lines (45 loc) · 1.21 KB
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
services:
budget-db:
container_name: budget-db
image: postgres
env_file:
- ./.env
ports:
- "5432:5432"
environment:
- POSTGRES_PASSWORD=$POSTGRESQL_PASSWORD
- POSTGRES_USER=$POSTGRESQL_USERNAME
- POSTGRES_DB=$POSTGRESQL_DB_NAME
volumes:
- .data:/var/lib/postgresql/data
restart: unless-stopped
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U postgres" ]
interval: 10s
timeout: 5s
retries: 5
budget-project-web:
container_name: budget-project-web
image: bladeours/budget-project-web
env_file:
- ./.env
ports:
- "$WEB_APP_LOCAL_PORT:80"
restart: unless-stopped
budget-project:
container_name: budget-project
env_file:
- ./.env
image: bladeours/budget-project
ports:
- "8080:8080"
environment:
SPRING_APPLICATION_JSON: '{
"spring.datasource.url" : "jdbc:postgresql://budget-db:5432/$POSTGRESQL_DB_NAME",
"spring.datasource.username" : "$POSTGRESQL_USERNAME",
"spring.datasource.password" : "$POSTGRESQL_PASSWORD",
"cors.origins" : "http://localhost"
}'
depends_on:
- budget-db
restart: unless-stopped