1
0
mirror of https://github.com/containous/traefik.git synced 2025-10-06 11:33:17 +03:00

Merge branch 'v1.5' into master

This commit is contained in:
Fernandez Ludovic
2017-12-15 22:16:48 +01:00
44 changed files with 1035 additions and 463 deletions

View File

@@ -152,9 +152,22 @@ func priority(value int) func(*types.Frontend) {
}
}
func redirect(value string) func(*types.Frontend) {
func redirectEntryPoint(name string) func(*types.Frontend) {
return func(f *types.Frontend) {
f.Redirect = value
if f.Redirect == nil {
f.Redirect = &types.Redirect{}
}
f.Redirect.EntryPoint = name
}
}
func redirectRegex(regex, replacement string) func(*types.Frontend) {
return func(f *types.Frontend) {
if f.Redirect == nil {
f.Redirect = &types.Redirect{}
}
f.Redirect.Regex = regex
f.Redirect.Replacement = replacement
}
}