2019-04-09 15:24:05 +00:00
|
|
|
[global]
|
2019-07-01 09:30:05 +00:00
|
|
|
checkNewVersion = false
|
|
|
|
sendAnonymousUsage = false
|
2019-04-09 15:24:05 +00:00
|
|
|
|
2018-11-27 16:42:04 +00:00
|
|
|
[log]
|
2019-07-01 09:30:05 +00:00
|
|
|
level = "DEBUG"
|
2022-11-21 17:36:05 +00:00
|
|
|
noColor = true
|
2018-07-31 09:28:03 +00:00
|
|
|
|
2019-04-15 09:14:05 +00:00
|
|
|
[entryPoints]
|
|
|
|
[entryPoints.web]
|
2019-03-14 08:30:04 +00:00
|
|
|
address = ":8888"
|
2018-07-31 09:28:03 +00:00
|
|
|
|
2020-01-23 15:36:08 +00:00
|
|
|
[entryPoints.websecure]
|
2019-03-14 08:30:04 +00:00
|
|
|
address = ":8443"
|
2018-07-31 09:28:03 +00:00
|
|
|
|
|
|
|
[api]
|
2019-09-06 13:08:04 +00:00
|
|
|
insecure = true
|
2018-07-31 09:28:03 +00:00
|
|
|
|
2019-07-15 08:22:03 +00:00
|
|
|
[providers.file]
|
|
|
|
filename = "{{ .SelfFilename }}"
|
2019-03-14 08:30:04 +00:00
|
|
|
|
2019-07-01 09:30:05 +00:00
|
|
|
## dynamic configuration ##
|
|
|
|
|
2019-03-14 08:30:04 +00:00
|
|
|
[http.routers]
|
|
|
|
[http.routers.router1]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`example.com`)"
|
|
|
|
middlewares = ["redirect-https"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router1TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`example.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router1TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router2]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`example2.com`)"
|
|
|
|
middlewares = ["redirect-https", "api-slash-strip"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router2TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`example2.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router2TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router3]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`test.com`)"
|
|
|
|
middlewares = ["redirect-https", "foo-add-prefix"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router3TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`test.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router3TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router4]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`test2.com`)"
|
|
|
|
middlewares = ["redirect-https", "foo-slash-add-prefix"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router4TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`test2.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router4TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router5]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`foo.com`)"
|
|
|
|
middlewares = ["redirect-https", "id-strip-regex-prefix"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router5TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`foo.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router5TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router6]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`foo2.com`)"
|
|
|
|
middlewares = ["redirect-https", "id-slash-strip-regex-prefix"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router6TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`foo2.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router6TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router7]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`bar.com`)"
|
|
|
|
middlewares = ["redirect-https", "api-regex-replace"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router7TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`bar.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router7TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router8]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`bar2.com`)"
|
|
|
|
middlewares = ["redirect-https", "api-slash-regex-replace"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router8TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`bar2.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router8TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router9]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`pow.com`)"
|
|
|
|
middlewares = ["redirect-https", "api-replace-path"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router9TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`pow.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router9TLS.tls]
|
|
|
|
|
|
|
|
[http.routers.router10]
|
2019-04-15 09:14:05 +00:00
|
|
|
entryPoints = [ "web" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`pow2.com`)"
|
|
|
|
middlewares = ["redirect-https", "api-slash-replace-path"]
|
|
|
|
service = "service1"
|
|
|
|
|
|
|
|
[http.routers.router10TLS]
|
2020-01-23 15:36:08 +00:00
|
|
|
entryPoints = [ "websecure" ]
|
2019-03-14 08:30:04 +00:00
|
|
|
rule = "Host(`pow2.com`)"
|
|
|
|
service = "service1"
|
|
|
|
[http.routers.router10TLS.tls]
|
|
|
|
|
|
|
|
[http.middlewares]
|
2019-07-01 09:30:05 +00:00
|
|
|
[http.middlewares.api-strip.stripPrefix]
|
|
|
|
prefixes = ["/api"]
|
|
|
|
[http.middlewares.api-slash-strip.stripPrefix]
|
|
|
|
prefixes = ["/api/"]
|
|
|
|
[http.middlewares.foo-add-prefix.addPrefix]
|
|
|
|
prefix = "/foo"
|
|
|
|
[http.middlewares.foo-slash-add-prefix.addPrefix]
|
|
|
|
prefix = "/foo/"
|
|
|
|
[http.middlewares.id-strip-regex-prefix.stripPrefixRegex]
|
2019-09-03 18:32:03 +00:00
|
|
|
regex = ["/[a-z]+"]
|
2019-07-01 09:30:05 +00:00
|
|
|
[http.middlewares.id-slash-strip-regex-prefix.stripPrefixRegex]
|
2019-09-03 18:32:03 +00:00
|
|
|
regex = ["/[a-z]+/"]
|
2019-07-01 09:30:05 +00:00
|
|
|
[http.middlewares.api-regex-replace.replacePathRegex]
|
|
|
|
regex = "/api"
|
|
|
|
replacement = "/"
|
|
|
|
[http.middlewares.api-slash-regex-replace.replacePathRegex]
|
|
|
|
regex = "/api/"
|
|
|
|
replacement = "/"
|
|
|
|
[http.middlewares.api-replace-path.replacePath]
|
|
|
|
path = "/api"
|
|
|
|
[http.middlewares.api-slash-replace-path.replacePath]
|
|
|
|
path = "/api/"
|
2019-03-14 08:30:04 +00:00
|
|
|
[http.middlewares.redirect-https.redirectScheme]
|
2019-07-01 09:30:05 +00:00
|
|
|
scheme = "https"
|
|
|
|
port = "8443"
|
2018-11-14 09:18:03 +00:00
|
|
|
|
2019-03-14 08:30:04 +00:00
|
|
|
[http.services]
|
|
|
|
[http.services.service1]
|
2019-07-01 09:30:05 +00:00
|
|
|
[http.services.service1.loadBalancer]
|
|
|
|
[[http.services.service1.loadBalancer.servers]]
|
2019-03-14 08:30:04 +00:00
|
|
|
url = "http://127.0.0.1:80"
|