-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtraefik.config.toml
50 lines (41 loc) · 1.36 KB
/
traefik.config.toml
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
48
49
50
[http]
[http.routers]
#########################################################################
# http #
[http.routers.http-to-app]
# You can change the rules here and make it more complex. Check traefik
# docs!
rule = "Host(`app.example.com`)"
service = "app"
entryPoints = ["http"]
# enable if u want redirect to https
middlewares = ["redirect"]
## https #
[http.routers.https-to-app]
rule = "Host(`app.example.com`)"
service = "app"
entryPoints = ["https"]
middlewares = ["app-compress","app-ratelimit","app-latency"]
[http.routers.https-to-app.tls]
[http.services]
# service
[http.services.app]
[http.services.app.loadBalancer]
passHostHeader = true
[[http.services.app.loadBalancer.servers]]
# This is where your dev app lives.
url = "http://url/"
########################################################################
[http.middlewares]
[http.middlewares.redirect.redirectScheme]
scheme = "https"
[http.middlewares.app-compress.compress]
[http.middlewares.app-ratelimit.rateLimit]
average = 100
burst = 50
[http.middlewares.app-latency.circuitBreaker]
expression = "LatencyAtQuantileMS(50.0) > 100"
[tls]
[tls.certificates]
certFile = "/data/fullchain.pem"
keyFile = "/data/privkey.pem"