Skip to content

Commit

Permalink
embed: add a warning to log that we changed certificate for metrics e…
Browse files Browse the repository at this point in the history
…ndpoints

Signed-off-by: Gladkov Alexey <agladkov@redhat.com>
  • Loading branch information
legionus committed Mar 1, 2019
1 parent fa73854 commit 1da4d75
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions embed/etcd.go
Original file line number Diff line number Diff line change
Expand Up @@ -765,6 +765,12 @@ func (e *Etcd) serveMetrics() (err error) {
tlsInfo := &e.cfg.ClientTLSInfo
if !e.cfg.MetricsTLSInfo.Empty() {
tlsInfo = &e.cfg.MetricsTLSInfo
msg := "ignoring client certificates for additional metrics and health endpoints since metrics certificates given"
if e.cfg.logger != nil {
e.cfg.logger.Warn(msg)
} else {
plog.Warningf(msg)
}
}
if murl.Scheme == "http" {
tlsInfo = nil
Expand Down

0 comments on commit 1da4d75

Please sign in to comment.