-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdocker-compose.yml
40 lines (37 loc) · 972 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
version: '3.9'
services:
be-app:
image: 'calendarapp-be:latest'
build:
context: ./backend
dockerfile: ./dockerfile
container_name: calendarapp-be
depends_on:
- postgres-db
environment:
- POSTGRES_USER=myuser
- POSTGRES_PASSWORD=mypassword
- SPRING_DATASOURCE_URL=jdbc:postgresql://postgres-db:5432/mydatabase
- SPRING_DATASOURCE_USERNAME=myuser
- SPRING_DATASOURCE_PASSWORD=mypassword
- SPRING_JPA_HIBERNATE_DDL_AUTO=update
ports:
- "8080:8080"
profiles: ["be", "def"]
fe-app:
image: 'calendarapp-fe:latest'
build:
context: ./frontend
dockerfile: ./dockerfile
container_name: calendarapp-fe
ports:
- "4200:4200"
profiles: ["def"]
postgres-db:
image: postgres
container_name: postgres-db
environment:
- POSTGRES_USER=myuser
- POSTGRES_PASSWORD=mypassword
- POSTGRES_DB=mydatabase
profiles: ["be", "def"]