diff --git a/keda/templates/manager/deployment.yaml b/keda/templates/manager/deployment.yaml index b993ae94..7f84cc0e 100644 --- a/keda/templates/manager/deployment.yaml +++ b/keda/templates/manager/deployment.yaml @@ -86,9 +86,9 @@ spec: - "--metrics-server-service-name={{ .Values.operator.name }}-metrics-apiserver" - "--webhooks-service-name={{ .Values.webhooks.name }}" - "--k8s-cluster-domain={{ .Values.clusterDomain }}" + - "--enable-prometheus-metrics={{ .Values.prometheus.operator.enabled }}" {{- if .Values.prometheus.operator.enabled }} - "--metrics-bind-address=:{{ .Values.prometheus.operator.port }}" - - "--enable-prometheus-metrics={{ .Values.prometheus.operator.enabled }}" {{- end }} {{- if .Values.opentelemetry.operator.enabled }} - "--enable-opentelemetry-metrics={{ .Values.opentelemetry.operator.enabled}}" @@ -116,9 +116,11 @@ spec: failureThreshold: {{ .Values.operator.readinessProbe.failureThreshold }} successThreshold: {{ .Values.operator.readinessProbe.successThreshold }} ports: - - containerPort: 8080 - name: http + {{- if .Values.prometheus.operator.enabled }} + - containerPort: {{ .Values.prometheus.operator.port }} + name: metrics protocol: TCP + {{- end }} env: - name: WATCH_NAMESPACE value: {{ .Values.watchNamespace | quote }}