Documentation ¶
Index ¶
Constants ¶
View Source
const ( // PolicyAnnotation annotation name for dns policy. PolicyAnnotation = "dns-injector.ydkn.io/policy" // ConfigAnnotation annotation name for dns config. ConfigAnnotation = "dns-injector.ydkn.io/configmap" // ConfigMapDNSConfigKeyJSON data key for dnsConfig in JSON format. ConfigMapDNSConfigKeyJSON = "dnsConfig.json" // ConfigMapDNSConfigKeyYAML data key for dnsConfig in YAML format. ConfigMapDNSConfigKeyYAML = "dnsConfig.yaml" )
Variables ¶
View Source
var ErrorConfigNotExists = fmt.Errorf("config does not exist: ")
ErrorConfigNotExists referenced config could not be found.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler handle DNS injector webhook requests.
func NewHandler ¶
func NewHandler(config HandlerConfig) (*Handler, error)
NewHandler creates a new Handler with given configuration.
type HandlerConfig ¶
type HandlerConfig struct {
Logger *zap.SugaredLogger
}
HandlerConfig configuration for a DNS injector handler.
Click to show internal directories.
Click to hide internal directories.