-
Notifications
You must be signed in to change notification settings - Fork 17
/
docker-compose.traefik.yml
29 lines (26 loc) · 949 Bytes
/
docker-compose.traefik.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
version: "3.3"
services:
traefik:
image: "traefik:v2.2"
container_name: "traefik"
ports:
- "80:80"
- "443:443"
- "8080:8080"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- "./traefik/certs:/etc/traefik/certs"
- "./traefik/traefik.toml:/etc/traefik/traefik.toml"
- "./traefik/dyn.toml:/etc/traefik/dyn.toml"
core-app:
build: ./dotnetapp
labels:
- "traefik.enable=true"
- "traefik.http.services.app.loadbalancer.server.port=80"
- "traefik.http.routers.app.rule=Host(`localhost`)"
- "traefik.http.routers.app.entrypoints=websecure"
- "traefik.http.routers.app.tls=true"
- "traefik.http.routers.app-http.rule=Host(`localhost`)"
- "traefik.http.routers.app-http.entrypoints=web"
- "traefik.http.routers.app-http.middlewares=redirect-secure"
- "traefik.http.middlewares.redirect-secure.redirectscheme.scheme=https"