Add annotation to disable logs in a location (#2144)

This commit is contained in:
Manuel Alejandro de Brito Fontes 2018-02-25 11:38:54 -03:00 committed by GitHub
parent edb3be64ea
commit 0dee303ac2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 165 additions and 0 deletions

View file

@ -34,6 +34,7 @@ import (
"k8s.io/ingress-nginx/internal/ingress/annotations/defaultbackend"
"k8s.io/ingress-nginx/internal/ingress/annotations/healthcheck"
"k8s.io/ingress-nginx/internal/ingress/annotations/ipwhitelist"
"k8s.io/ingress-nginx/internal/ingress/annotations/log"
"k8s.io/ingress-nginx/internal/ingress/annotations/parser"
"k8s.io/ingress-nginx/internal/ingress/annotations/portinredirect"
"k8s.io/ingress-nginx/internal/ingress/annotations/proxy"
@ -87,6 +88,7 @@ type Ingress struct {
Whitelist ipwhitelist.SourceRange
XForwardedPrefix bool
SSLCiphers string
Logs log.Config
}
// Extractor defines the annotation parsers to be used in the extraction of annotations
@ -124,6 +126,7 @@ func NewAnnotationExtractor(cfg resolver.Resolver) Extractor {
"Whitelist": ipwhitelist.NewParser(cfg),
"XForwardedPrefix": xforwardedprefix.NewParser(cfg),
"SSLCiphers": sslcipher.NewParser(cfg),
"Logs": log.NewParser(cfg),
},
}
}