-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
35 lines (29 loc) · 1.14 KB
/
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
services:
backtesting-app:
build:
context: .
dockerfile: Dockerfile
restart: always
environment:
- DOMAIN=${DOMAIN}
command: streamlit run ./src/app.py --server.port 8501
labels:
- traefik.enable=true
- traefik.docker.network=traefik-public
- traefik.constraint-label=traefik-public
- traefik.http.services.backtesting-app.loadbalancer.server.port=8501
- traefik.http.routers.backtesting-app-http.rule=Host(`backtesting-app.${DOMAIN?Variable not set}`)
- traefik.http.routers.backtesting-app-http.entrypoints=http
- traefik.http.routers.backtesting-app-https.rule=Host(`backtesting-app.${DOMAIN?Variable not set}`)
- traefik.http.routers.backtesting-app-https.entrypoints=https
- traefik.http.routers.backtesting-app-https.tls=true
- traefik.http.routers.backtesting-app-https.tls.certresolver=le
# Enable redirection for HTTP and HTTPS
- traefik.http.routers.backtesting-app-http.middlewares=https-redirect
networks:
- traefik-public
- default
networks:
traefik-public:
# allow setting it to false for testing
external: true