feat(k8s): add error pages annotations.

This commit is contained in:
Fernandez Ludovic 2017-12-21 17:47:50 +01:00 committed by Traefiker
parent 5bfd6acd52
commit 4c0d6e211b
4 changed files with 74 additions and 0 deletions

View file

@ -220,6 +220,8 @@ func (p *Provider) loadIngresses(k8sClient Client) (*types.Configuration, error)
whitelistSourceRange := label.GetSliceStringValue(i.Annotations, annotationKubernetesWhitelistSourceRange)
errorPages := label.ParseErrorPages(i.Annotations, label.Prefix+label.BaseFrontendErrorPage, label.RegexpFrontendErrorPage)
templateObjects.Frontends[r.Host+pa.Path] = &types.Frontend{
Backend: r.Host + pa.Path,
PassHostHeader: passHostHeader,
@ -231,6 +233,7 @@ func (p *Provider) loadIngresses(k8sClient Client) (*types.Configuration, error)
Redirect: getFrontendRedirect(i),
EntryPoints: entryPoints,
Headers: getHeader(i),
Errors: errorPages,
}
}