Properly load k8s audit configuration (#2158)
This commit is contained in:
parent
38ab6be7c2
commit
3132aa54b7
|
@ -94,6 +94,11 @@ func (ka *KubernetesAuditSource) UnmarshalConfig(yamlConfig []byte) error {
|
||||||
func (ka *KubernetesAuditSource) Configure(config []byte, logger *log.Entry) error {
|
func (ka *KubernetesAuditSource) Configure(config []byte, logger *log.Entry) error {
|
||||||
ka.logger = logger
|
ka.logger = logger
|
||||||
|
|
||||||
|
err := ka.UnmarshalConfig(config)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
ka.logger.Tracef("K8SAudit configuration: %+v", ka.config)
|
ka.logger.Tracef("K8SAudit configuration: %+v", ka.config)
|
||||||
|
|
||||||
ka.addr = fmt.Sprintf("%s:%d", ka.config.ListenAddr, ka.config.ListenPort)
|
ka.addr = fmt.Sprintf("%s:%d", ka.config.ListenAddr, ka.config.ListenPort)
|
||||||
|
|
Loading…
Reference in a new issue