diff --git a/config/default/metrics_service.yaml b/config/default/metrics_service.yaml index 13c1970..54f8134 100644 --- a/config/default/metrics_service.yaml +++ b/config/default/metrics_service.yaml @@ -15,3 +15,4 @@ spec: targetPort: 8443 selector: control-plane: controller-manager + app.kubernetes.io/name: workload-operator diff --git a/config/prometheus/kustomization.yaml b/config/prometheus/kustomization.yaml index 02c2c54..fa2b701 100644 --- a/config/prometheus/kustomization.yaml +++ b/config/prometheus/kustomization.yaml @@ -2,3 +2,4 @@ apiVersion: kustomize.config.k8s.io/v1alpha1 kind: Component resources: - monitor.yaml + - metrics_service.yaml diff --git a/config/prometheus/metrics_service.yaml b/config/prometheus/metrics_service.yaml new file mode 100644 index 0000000..54f8134 --- /dev/null +++ b/config/prometheus/metrics_service.yaml @@ -0,0 +1,18 @@ +apiVersion: v1 +kind: Service +metadata: + labels: + control-plane: controller-manager + app.kubernetes.io/name: workload-operator + app.kubernetes.io/managed-by: kustomize + name: controller-manager-metrics-service + namespace: system +spec: + ports: + - name: https + port: 8443 + protocol: TCP + targetPort: 8443 + selector: + control-plane: controller-manager + app.kubernetes.io/name: workload-operator diff --git a/config/prometheus/monitor.yaml b/config/prometheus/monitor.yaml index 15157ab..1e26e07 100644 --- a/config/prometheus/monitor.yaml +++ b/config/prometheus/monitor.yaml @@ -28,3 +28,4 @@ spec: selector: matchLabels: control-plane: controller-manager + app.kubernetes.io/name: workload-operator