diff --git a/charts/function-mesh-operator/templates/controller-manager-deployment.yaml b/charts/function-mesh-operator/templates/controller-manager-deployment.yaml index b30395dc..d367dd24 100644 --- a/charts/function-mesh-operator/templates/controller-manager-deployment.yaml +++ b/charts/function-mesh-operator/templates/controller-manager-deployment.yaml @@ -98,21 +98,4 @@ spec: priorityClassName: {{ .Values.controllerManager.priorityClassName }} {{- end }} volumes: - {{- include "function-mesh-operator.volumes" . | nindent 6 -}} ---- -apiVersion: v1 -kind: Service -metadata: - name: function-mesh-controller-manager-metrics-service - namespace: {{ .Release.Namespace }} - labels: - {{- include "function-mesh-operator.labels" . | nindent 4 }} -spec: - ports: - - name: http-metrics - port: {{ .Values.controllerManager.metrics.port }} - protocol: TCP - targetPort: {{ .Values.controllerManager.metrics.port }} - selector: - app.kubernetes.io/instance: {{ .Release.Name }} - app.kubernetes.io/component: controller-manager \ No newline at end of file + {{- include "function-mesh-operator.volumes" . | nindent 6 -}} \ No newline at end of file diff --git a/charts/function-mesh-operator/templates/controller-manager-metrics-service.yaml b/charts/function-mesh-operator/templates/controller-manager-metrics-service.yaml new file mode 100644 index 00000000..7944aae8 --- /dev/null +++ b/charts/function-mesh-operator/templates/controller-manager-metrics-service.yaml @@ -0,0 +1,16 @@ +apiVersion: v1 +kind: Service +metadata: + name: function-mesh-controller-manager-metrics-service + namespace: {{ .Release.Namespace }} + labels: + {{- include "function-mesh-operator.labels" . | nindent 4 }} +spec: + ports: + - name: http-metrics + port: {{ .Values.controllerManager.metrics.port }} + protocol: TCP + targetPort: {{ .Values.controllerManager.metrics.port }} + selector: + app.kubernetes.io/instance: {{ .Release.Name }} + app.kubernetes.io/component: controller-manager \ No newline at end of file diff --git a/config/default/kustomization.yaml b/config/default/kustomization.yaml index de30a595..89ee3068 100644 --- a/config/default/kustomization.yaml +++ b/config/default/kustomization.yaml @@ -22,7 +22,7 @@ bases: # [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER'. 'WEBHOOK' components are required. - ../certmanager # [PROMETHEUS] To enable prometheus monitor, uncomment all sections with 'PROMETHEUS'. -- ../prometheus +#- ../prometheus patchesStrategicMerge: # Protect the /metrics endpoint by putting it behind auth.