Skip to content

Commit

Permalink
rename namespace to operator-namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
TheoBrigitte committed Dec 16, 2024
1 parent 8df047c commit 1d520dc
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion helm/observability-operator/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ spec:
- --monitoring-sharding-scale-up-series-count={{ $.Values.monitoring.sharding.scaleUpSeriesCount }}
- --monitoring-sharding-scale-down-percentage={{ $.Values.monitoring.sharding.scaleDownPercentage }}
- --monitoring-wal-truncate-frequency={{ $.Values.monitoring.wal.truncateFrequency }}
- --namespace={{ include "resource.default.namespace" . }}
- --operator-namespace={{ include "resource.default.namespace" . }}
{{- if .Values.monitoring.prometheusVersion }}
- --prometheus-version={{ $.Values.monitoring.prometheusVersion }}
{{- end }}
Expand Down
4 changes: 2 additions & 2 deletions internal/controller/alertmanager_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func SetupAlertmanagerReconciler(mgr ctrl.Manager, conf config.Config) error {
}

// Filter only the Alertmanager secret created by the observability-operator Helm chart
secretPredicate := predicates.NewAlertmanagerSecretPredicate(conf.Monitoring.AlertmanagerSecretName, conf.Namespace)
secretPredicate := predicates.NewAlertmanagerSecretPredicate(conf.Monitoring.AlertmanagerSecretName, conf.OperatorNamespace)

// Filter only the Mimir Alertmanager pod
podPredicate := predicates.NewAlertmanagerPodPredicate()
Expand All @@ -59,7 +59,7 @@ func podEventHandler(conf config.Config) handler.EventHandler {
{
NamespacedName: types.NamespacedName{
Name: conf.Monitoring.AlertmanagerSecretName,
Namespace: conf.Namespace,
Namespace: conf.OperatorNamespace,
},
},
}
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func main() {
"If set the metrics endpoint is served securely")
flag.BoolVar(&conf.EnableHTTP2, "enable-http2", false,
"If set, HTTP/2 will be enabled for the metrics and webhook servers")
flag.StringVar(&conf.Namespace, "namespace", "",
flag.StringVar(&conf.OperatorNamespace, "operator-namespace", "",
"The namespace where the observability-operator is running.")

// Management cluster configuration flags.
Expand Down
2 changes: 1 addition & 1 deletion pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ type Config struct {
ProbeAddr string
SecureMetrics bool
EnableHTTP2 bool
Namespace string
OperatorNamespace string

ManagementCluster common.ManagementCluster

Expand Down

0 comments on commit 1d520dc

Please sign in to comment.