Skip to content

Commit

Permalink
Ensure metrics enabled and served securely by default
Browse files Browse the repository at this point in the history
Signed-off-by: Swati Sehgal <[email protected]>
  • Loading branch information
swatisehgal committed Apr 16, 2024
1 parent 85a2139 commit 5e21de9
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,16 @@ const (
)

const (
defaultWebhookPort = 9443
defaultMetricsAddr = ":8080"
defaultProbeAddr = ":8081"
defaultImage = ""
defaultNamespace = "numaresources-operator"
defaultCertsDir = "/etc/secrets/nrop"
defaultTLSCert = defaultCertsDir + "tls.crt"
defaultTLSKey = defaultCertsDir + "tls.key"
caCert = defaultCertsDir + "/ca.crt"
defaultWebhookPort = 9443
defaultMetricsAddr = ":8080"
defaultMetricsEnabled = true
defaultProbeAddr = ":8081"
defaultImage = ""
defaultNamespace = "numaresources-operator"
defaultCertsDir = "/etc/secrets/nrop"
defaultTLSCert = defaultCertsDir + "tls.crt"
defaultTLSKey = defaultCertsDir + "tls.key"
caCert = defaultCertsDir + "/ca.crt"
)

var (
Expand Down Expand Up @@ -128,6 +129,8 @@ func (pa *Params) SetDefaults() {
pa.probeAddr = defaultProbeAddr
pa.render.Namespace = defaultNamespace
pa.render.Image = defaultImage
pa.enableMetrics = defaultMetricsEnabled

}

func (pa *Params) FromFlags() {
Expand Down

0 comments on commit 5e21de9

Please sign in to comment.