SchemeRedirect Middleware

Co-authored-by: jbdoumenjou <jb.doumenjou@gmail.com>
This commit is contained in:
Gérald Croës 2019-01-21 23:30:04 -08:00 committed by Traefiker Bot
parent 04958c6951
commit a433e469cc
11 changed files with 407 additions and 66 deletions

View file

@ -6,9 +6,6 @@ logLevel = "DEBUG"
[entryPoints.http]
address = ":8888"
[entryPoints.http.redirect]
entryPoint = "https"
[entryPoints.https]
address = ":8443"
[entryPoints.https.tls]
@ -92,9 +89,9 @@ logLevel = "DEBUG"
path = "/api"
[Middlewares.api-slash-replace-path.ReplacePath]
path = "/api/"
[Middlewares.redirect-https.redirect]
regex = "^(?:https?://)?([\\w\\._-]+)(?::\\d+)?(.*)$"
replacement = "https://${1}:8443${2}"
[Middlewares.redirect-https.redirectScheme]
scheme = "https"
port = "8443"
[Services]
[Services.service1]