-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose-prod.yml
44 lines (38 loc) · 1.1 KB
/
docker-compose-prod.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
version: '3.8'
networks:
private:
external:
name: private
web:
external:
name: web
services:
#---------------------
# api
#---------------------
prod-api:
build:
context: .
args:
- PATH_OF_WAR=${PATH_OF_WAR}
image: prod-api
container_name: prod-api
depends_on:
- mysql
environment:
spring.datasource.username: ${MYSQL_USERNAME}
spring.datasource.password: ${MYSQL_ROOT_PASSWORD}
spring.profiles.active: ${ENV}
spring.datasource.url: jdbc:mysql://mysql:3306/${MYSQL_DATABASE}?serverTimezone=Europe/Berlin
server.port: 80
labels:
- traefik.enable=true
- "traefik.http.routers.prod-api.entrypoints=websecure"
- traefik.http.routers.prod-api.rule=Host(`api.dsp4-5archio19-ah-je-gh-yb.fr`)
- traefik.http.services.prod-api.loadbalancer.server.port=80
- "traefik.http.routers.prod-api.tls.certresolver=lets-encr"
#prochaine ligne est peut etre inutile
- traefik.http.routers.prod-api.middlewares=corsheaders
networks:
- private
- web