Last active
November 14, 2019 09:48
-
-
Save korchasa/69ec668507a5e7f1d92e04d71ec08cf9 to your computer and use it in GitHub Desktop.
Traefik example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[entryPoints] | |
[entryPoints.web] | |
address = ":8888" | |
[providers] | |
[providers.file] | |
filename = "traefik_conf.toml" | |
watch = true | |
[log] | |
level = "DEBUG" | |
[accessLog] | |
[metrics] | |
[metrics.prometheus] | |
[api] | |
dashboard = true | |
insecure = true | |
[ping] | |
entryPoint = "ping" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[http] | |
[http.routers] | |
[http.routers.dash] | |
rule = "PathPrefix(`/api`) || PathPrefix(`/dashboard`)" | |
service = "api@internal" | |
[http.routers.httbin-org] | |
rule = "PathPrefix(`/proxy`)" | |
middlewares = ["remove-proxy-from-path", "rate-limit-5", "retry-4"] | |
service = "httpbin-org" | |
[http.middlewares] | |
[http.middlewares.remove-proxy-from-path.replacePathRegex] | |
regex = "^/proxy/(.*)" | |
replacement = "/$1" | |
[http.middlewares.rate-limit-5.rateLimit] | |
average = 5 | |
[http.middlewares.retry-4.retry] | |
attempts = 4 | |
[http.services] | |
[http.services.httpbin-org.loadBalancer] | |
[[http.services.httpbin-org.loadBalancer.servers]] | |
url = "http://httpbin.org/" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment