diff --git a/chart/templates/controller-manager-metrics-http-service_service.yaml b/chart/templates/controller-manager-metrics-http-service_service.yaml new file mode 100644 index 00000000..d74c6992 --- /dev/null +++ b/chart/templates/controller-manager-metrics-http-service_service.yaml @@ -0,0 +1,16 @@ +apiVersion: v1 +kind: Service +metadata: + labels: {{ include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: manager + app.kubernetes.io/part-of: uffizzi + name: {{ include "common.names.fullname" . | trunc 55 | trimSuffix "-" }}-http-metrics + namespace: {{ .Release.Namespace | quote }} +spec: + ports: + - name: http + port: 8080 + protocol: TCP + targetPort: https + selector: + control-plane: controller-manager diff --git a/chart/templates/controller-manager_deployment.yaml b/chart/templates/controller-manager_deployment.yaml index 7a2c76d5..7ce180a9 100644 --- a/chart/templates/controller-manager_deployment.yaml +++ b/chart/templates/controller-manager_deployment.yaml @@ -66,6 +66,10 @@ spec: command: - /manager image: "{{ .Values.image.repository }}:{{ default .Chart.AppVersion .Values.image.tag }}" + ports: + - containerPort: 8080 + name: http + protocol: TCP livenessProbe: httpGet: path: /healthz diff --git a/src/test/e2e/metrics_test.go b/src/test/e2e/metrics_test.go new file mode 100644 index 00000000..949061f2 --- /dev/null +++ b/src/test/e2e/metrics_test.go @@ -0,0 +1,4 @@ +// contains helper functions to test metrics exported by +// the uffizzi cluster operator + +package e2e diff --git a/src/test/e2e/ucluster_lifecycle_test.go b/src/test/e2e/ucluster_lifecycle_test.go index bc1a88ba..a50e2c49 100644 --- a/src/test/e2e/ucluster_lifecycle_test.go +++ b/src/test/e2e/ucluster_lifecycle_test.go @@ -1,3 +1,6 @@ +// ucluster_lifecycle_test contains helper functions which are used +// for testing the lifecycle of the UffizziCluster resource. + package e2e import (