From 7c554c2fbeca8bc17b9233c47c8d540fcbe636b6 Mon Sep 17 00:00:00 2001 From: MohammedAbdi Date: Tue, 14 May 2024 12:27:36 -0400 Subject: [PATCH] clean up Signed-off-by: MohammedAbdi --- VERSION | 2 +- ...nitoring.coreos.com_v1_servicemonitor.yaml | 18 ++ ...r-manager-metrics-service_v1_service.yaml} | 14 +- ...nitoring.coreos.com_v1_servicemonitor.yaml | 23 --- .../susql-operator.clusterserviceversion.yaml | 83 +++++----- bundle/metadata/dependencies.yaml | 6 - config/default/kustomization.yaml | 2 +- config/default/manager_auth_proxy_patch.yaml | 2 +- config/default/manager_config_patch.yaml | 2 +- config/manager/kustomization.yaml | 2 +- config/manager/manager.yaml | 69 ++++---- .../susql-operator.clusterserviceversion.yaml | 154 +++++++++++++++++- config/manifests/kustomization.yaml | 33 ++-- config/prometheus/monitor.yaml | 15 +- config/rbac/auth_proxy_role_binding.yaml | 2 +- config/rbac/auth_proxy_service.yaml | 14 +- config/rbac/leader_election_role_binding.yaml | 2 +- config/rbac/role_binding.yaml | 2 +- config/rbac/service_account.yaml | 4 +- 19 files changed, 285 insertions(+), 164 deletions(-) create mode 100644 bundle/manifests/susql-operator-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml rename bundle/manifests/{susql-operator-susql-controller-manager-metrics-service_v1_service.yaml => susql-operator-controller-manager-metrics-service_v1_service.yaml} (57%) delete mode 100644 bundle/manifests/susql-operator-susql-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml delete mode 100644 bundle/metadata/dependencies.yaml diff --git a/VERSION b/VERSION index 9789c4c..ceddfb2 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.0.14 +0.0.15 diff --git a/bundle/manifests/susql-operator-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml b/bundle/manifests/susql-operator-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml new file mode 100644 index 0000000..860cf58 --- /dev/null +++ b/bundle/manifests/susql-operator-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml @@ -0,0 +1,18 @@ +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + labels: + app.kubernetes.io/component: metrics + app.kubernetes.io/created-by: susql-operator + app.kubernetes.io/instance: controller-manager-metrics-monitor + app.kubernetes.io/managed-by: kustomize + app.kubernetes.io/name: servicemonitor + app.kubernetes.io/part-of: susql-operator + name: susql-operator-controller-manager-metrics-monitor +spec: + endpoints: + - port: metrics + selector: + matchLabels: + app.kubernetes.io/name: service + app.kubernetes.io/part-of: susql-operator diff --git a/bundle/manifests/susql-operator-susql-controller-manager-metrics-service_v1_service.yaml b/bundle/manifests/susql-operator-controller-manager-metrics-service_v1_service.yaml similarity index 57% rename from bundle/manifests/susql-operator-susql-controller-manager-metrics-service_v1_service.yaml rename to bundle/manifests/susql-operator-controller-manager-metrics-service_v1_service.yaml index 511522f..193a5fb 100644 --- a/bundle/manifests/susql-operator-susql-controller-manager-metrics-service_v1_service.yaml +++ b/bundle/manifests/susql-operator-controller-manager-metrics-service_v1_service.yaml @@ -5,19 +5,19 @@ metadata: labels: app.kubernetes.io/component: kube-rbac-proxy app.kubernetes.io/created-by: susql-operator - app.kubernetes.io/instance: susql-controller-manager-metrics-service + app.kubernetes.io/instance: controller-manager-metrics-service app.kubernetes.io/managed-by: kustomize app.kubernetes.io/name: service app.kubernetes.io/part-of: susql-operator - control-plane: susql-controller-manager - name: susql-operator-susql-controller-manager-metrics-service + name: susql-operator-controller-manager-metrics-service spec: ports: - - name: https - port: 8443 + - name: metrics + port: 8082 protocol: TCP - targetPort: https + targetPort: metrics selector: - control-plane: susql-controller-manager + app.kubernetes.io/component: manager + app.kubernetes.io/instance: controller-manager status: loadBalancer: {} diff --git a/bundle/manifests/susql-operator-susql-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml b/bundle/manifests/susql-operator-susql-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml deleted file mode 100644 index 68d62a7..0000000 --- a/bundle/manifests/susql-operator-susql-controller-manager-metrics-monitor_monitoring.coreos.com_v1_servicemonitor.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: monitoring.coreos.com/v1 -kind: ServiceMonitor -metadata: - labels: - app.kubernetes.io/component: metrics - app.kubernetes.io/created-by: susql-operator - app.kubernetes.io/instance: susql-controller-manager-metrics-monitor - app.kubernetes.io/managed-by: kustomize - app.kubernetes.io/name: servicemonitor - app.kubernetes.io/part-of: susql-operator - control-plane: susql-controller-manager - name: susql-operator-susql-controller-manager-metrics-monitor -spec: - endpoints: - - bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token - path: /metrics - port: https - scheme: https - tlsConfig: - insecureSkipVerify: true - selector: - matchLabels: - control-plane: susql-controller-manager diff --git a/bundle/manifests/susql-operator.clusterserviceversion.yaml b/bundle/manifests/susql-operator.clusterserviceversion.yaml index dd86636..40d22cf 100644 --- a/bundle/manifests/susql-operator.clusterserviceversion.yaml +++ b/bundle/manifests/susql-operator.clusterserviceversion.yaml @@ -22,14 +22,14 @@ metadata: ] capabilities: Basic Install categories: Monitoring - containerImage: quay.io/sustainable_computing_io/susql_operator:0.0.14 - createdAt: "2024-04-30T07:27:57Z" + containerImage: quay.io/sustainable_computing_io/susql_operator:0.0.15 + createdAt: "2024-05-14T16:24:18Z" description: 'Aggregates energy data from pods tagged with SusQL labels ' operators.operatorframework.io/builder: operator-sdk-v1.34.1 operators.operatorframework.io/project_layout: go.kubebuilder.io/v4 repository: https://github.com/sustainable-computing-io/susql-operator support: https://github.com/sustainable-computing-io/susql-operator/issues - name: susql-operator.v0.0.14 + name: susql-operator.v0.0.15 namespace: placeholder spec: apiservicedefinitions: {} @@ -147,54 +147,48 @@ spec: - get - list - watch - serviceAccountName: susql-operator-susql-controller-manager + serviceAccountName: susql-operator-controller-manager deployments: - label: app.kubernetes.io/component: manager - app.kubernetes.io/created-by: susql-operator - app.kubernetes.io/instance: susql-controller-manager - app.kubernetes.io/managed-by: kustomize + app.kubernetes.io/instance: controller-manager app.kubernetes.io/name: deployment app.kubernetes.io/part-of: susql-operator - control-plane: susql-controller-manager - name: susql-operator-susql-controller-manager + name: susql-operator-controller spec: replicas: 1 selector: matchLabels: - control-plane: susql-controller-manager + app.kubernetes.io/component: manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/part-of: susql-operator strategy: {} template: metadata: annotations: kubectl.kubernetes.io/default-container: manager labels: - control-plane: susql-controller-manager + app.kubernetes.io/component: manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/part-of: susql-operator spec: + affinity: + nodeAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + nodeSelectorTerms: + - matchExpressions: + - key: kubernetes.io/arch + operator: In + values: + - amd64 + - arm64 + - ppc64le + - s390x + - key: kubernetes.io/os + operator: In + values: + - linux containers: - - args: - - --secure-listen-address=0.0.0.0:8443 - - --upstream=http://127.0.0.1:8082/ - - --logtostderr=true - - --v=0 - image: gcr.io/kubebuilder/kube-rbac-proxy:v0.14.1 - name: kube-rbac-proxy - ports: - - containerPort: 8443 - name: https - protocol: TCP - resources: - limits: - cpu: 500m - memory: 128Mi - requests: - cpu: 5m - memory: 64Mi - securityContext: - allowPrivilegeEscalation: false - capabilities: - drop: - - ALL - args: - --leader-elect - --kepler-prometheus-url=$(KEPLER-PROMETHEUS-URL) @@ -203,7 +197,7 @@ spec: - --susql-prometheus-metrics-url=$(SUSQL-PROMETHEUS-METRICS-URL) - --sampling-rate=$(SAMPLING-RATE) - --health-probe-bind-address=:8081 - - --metrics-bind-address=127.0.0.1:9999 + - --metrics-bind-address=127.0.0.1:8082 command: - /manager env: @@ -217,28 +211,25 @@ spec: value: http://0.0.0.0:8082 - name: SAMPLING-RATE value: "2" - image: quay.io/sustainable_computing_io/susql_operator:0.0.14 + image: quay.io/sustainable_computing_io/susql_operator:0.0.15 imagePullPolicy: IfNotPresent livenessProbe: httpGet: path: /healthz port: 8081 - initialDelaySeconds: 15 + initialDelaySeconds: 20 periodSeconds: 20 name: manager ports: - containerPort: 8082 - name: metric - protocol: TCP - - containerPort: 9999 - name: autometric + name: metrics protocol: TCP readinessProbe: httpGet: path: /readyz port: 8081 - initialDelaySeconds: 5 - periodSeconds: 10 + initialDelaySeconds: 20 + periodSeconds: 20 resources: limits: cpu: 500m @@ -253,7 +244,7 @@ spec: - ALL securityContext: runAsNonRoot: true - serviceAccountName: susql-operator-susql-controller-manager + serviceAccountName: susql-operator-controller-manager terminationGracePeriodSeconds: 10 permissions: - rules: @@ -288,7 +279,7 @@ spec: verbs: - create - patch - serviceAccountName: susql-operator-susql-controller-manager + serviceAccountName: susql-operator-controller-manager strategy: deployment installModes: - supported: true @@ -321,4 +312,4 @@ spec: provider: name: SusQL Operator Contributors url: https://github.com/sustainable-computing-io/susql-operator - version: 0.0.14 + version: 0.0.15 diff --git a/bundle/metadata/dependencies.yaml b/bundle/metadata/dependencies.yaml deleted file mode 100644 index 4e9dfa0..0000000 --- a/bundle/metadata/dependencies.yaml +++ /dev/null @@ -1,6 +0,0 @@ -dependencies: - - type: olm.gvk - value: - group: monitoring.coreos.com - kind: ServiceMonitor - version: v1 diff --git a/config/default/kustomization.yaml b/config/default/kustomization.yaml index 5b14036..e018219 100644 --- a/config/default/kustomization.yaml +++ b/config/default/kustomization.yaml @@ -30,7 +30,7 @@ patchesStrategicMerge: # Protect the /metrics endpoint by putting it behind auth. # If you want your controller-manager to expose the /metrics # endpoint w/o any authn/z, please comment the following line. -- manager_auth_proxy_patch.yaml +# - manager_auth_proxy_patch.yaml diff --git a/config/default/manager_auth_proxy_patch.yaml b/config/default/manager_auth_proxy_patch.yaml index d8ad988..da9c1ce 100644 --- a/config/default/manager_auth_proxy_patch.yaml +++ b/config/default/manager_auth_proxy_patch.yaml @@ -3,7 +3,7 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: susql-controller-manager + name: controller-manager namespace: system spec: template: diff --git a/config/default/manager_config_patch.yaml b/config/default/manager_config_patch.yaml index ff124ea..f6f5891 100644 --- a/config/default/manager_config_patch.yaml +++ b/config/default/manager_config_patch.yaml @@ -1,7 +1,7 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: susql-controller-manager + name: controller-manager namespace: system spec: template: diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index 35bbadf..5244e13 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -5,4 +5,4 @@ kind: Kustomization images: - name: controller newName: quay.io/sustainable_computing_io/susql_operator - newTag: 0.0.14 + newTag: 0.0.15 diff --git a/config/manager/manager.yaml b/config/manager/manager.yaml index a1017d1..fcb12fc 100644 --- a/config/manager/manager.yaml +++ b/config/manager/manager.yaml @@ -2,7 +2,6 @@ apiVersion: v1 kind: Namespace metadata: labels: - control-plane: susql-controller-manager app.kubernetes.io/name: namespace app.kubernetes.io/instance: system app.kubernetes.io/component: manager @@ -14,48 +13,49 @@ metadata: apiVersion: apps/v1 kind: Deployment metadata: - name: susql-controller-manager + name: controller namespace: system labels: - control-plane: susql-controller-manager app.kubernetes.io/name: deployment - app.kubernetes.io/instance: susql-controller-manager + app.kubernetes.io/instance: controller-manager app.kubernetes.io/component: manager - app.kubernetes.io/created-by: susql-operator app.kubernetes.io/part-of: susql-operator - app.kubernetes.io/managed-by: kustomize spec: selector: matchLabels: - control-plane: susql-controller-manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/component: manager + app.kubernetes.io/part-of: susql-operator replicas: 1 template: metadata: annotations: kubectl.kubernetes.io/default-container: manager labels: - control-plane: susql-controller-manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/component: manager + app.kubernetes.io/part-of: susql-operator spec: # TODO(user): Uncomment the following code to configure the nodeAffinity expression # according to the platforms which are supported by your solution. # It is considered best practice to support multiple architectures. You can # build your manager image using the makefile target docker-buildx. - # affinity: - # nodeAffinity: - # requiredDuringSchedulingIgnoredDuringExecution: - # nodeSelectorTerms: - # - matchExpressions: - # - key: kubernetes.io/arch - # operator: In - # values: - # - amd64 - # - arm64 - # - ppc64le - # - s390x - # - key: kubernetes.io/os - # operator: In - # values: - # - linux + affinity: + nodeAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + nodeSelectorTerms: + - matchExpressions: + - key: kubernetes.io/arch + operator: In + values: + - amd64 + - arm64 + - ppc64le + - s390x + - key: kubernetes.io/os + operator: In + values: + - linux securityContext: runAsNonRoot: true # TODO(user): For common cases that do not require escalating privileges @@ -89,7 +89,7 @@ spec: - --susql-prometheus-metrics-url=$(SUSQL-PROMETHEUS-METRICS-URL) - --sampling-rate=$(SAMPLING-RATE) - --health-probe-bind-address=:8081 - - --metrics-bind-address=127.0.0.1:9999 + - --metrics-bind-address=127.0.0.1:8082 image: '' imagePullPolicy: IfNotPresent name: manager @@ -102,23 +102,16 @@ spec: httpGet: path: /healthz port: 8081 - initialDelaySeconds: 15 + initialDelaySeconds: 20 periodSeconds: 20 readinessProbe: httpGet: path: /readyz port: 8081 - initialDelaySeconds: 5 - periodSeconds: 10 + initialDelaySeconds: 20 + periodSeconds: 20 # TODO(user): Configure the resources accordingly based on the project requirements. # More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - ports: - - containerPort: 8082 - protocol: TCP - name: metric - - containerPort: 9999 - protocol: TCP - name: autometric resources: limits: cpu: 500m @@ -126,5 +119,9 @@ spec: requests: cpu: 10m memory: 64Mi - serviceAccountName: susql-controller-manager + ports: + - containerPort: 8082 + protocol: TCP + name: metrics + serviceAccountName: controller-manager terminationGracePeriodSeconds: 10 diff --git a/config/manifests/bases/susql-operator.clusterserviceversion.yaml b/config/manifests/bases/susql-operator.clusterserviceversion.yaml index 07c8ca6..c587461 100644 --- a/config/manifests/bases/susql-operator.clusterserviceversion.yaml +++ b/config/manifests/bases/susql-operator.clusterserviceversion.yaml @@ -78,8 +78,158 @@ spec: mediatype: image/png install: spec: - deployments: null - strategy: "" + deployments: + - label: + app.kubernetes.io/component: manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/name: deployment + app.kubernetes.io/part-of: susql-operator + name: susql-operator-controller + spec: + replicas: 1 + selector: + matchLabels: + app.kubernetes.io/component: manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/part-of: susql-operator + strategy: {} + template: + metadata: + annotations: + kubectl.kubernetes.io/default-container: manager + labels: + app.kubernetes.io/component: manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/part-of: susql-operator + spec: + affinity: + nodeAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + nodeSelectorTerms: + - matchExpressions: + - key: kubernetes.io/arch + operator: In + values: + - amd64 + - arm64 + - ppc64le + - s390x + - key: kubernetes.io/os + operator: In + values: + - linux + containers: + - args: + - --secure-listen-address=0.0.0.0:8443 + - --upstream=http://127.0.0.1:8082/ + - --logtostderr=true + - --v=0 + image: gcr.io/kubebuilder/kube-rbac-proxy:v0.14.1 + name: kube-rbac-proxy + ports: + - containerPort: 8443 + name: https + protocol: TCP + resources: + limits: + cpu: 500m + memory: 128Mi + requests: + cpu: 5m + memory: 64Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + - args: + - --leader-elect + - --kepler-prometheus-url=$(KEPLER-PROMETHEUS-URL) + - --kepler-metric-name=$(KEPLER-METRIC-NAME) + - --susql-prometheus-database-url=$(SUSQL-PROMETHEUS-DATABASE-URL) + - --susql-prometheus-metrics-url=$(SUSQL-PROMETHEUS-METRICS-URL) + - --sampling-rate=$(SAMPLING-RATE) + - --health-probe-bind-address=:8081 + - --metrics-bind-address=127.0.0.1:8082 + command: + - /manager + env: + - name: KEPLER-PROMETHEUS-URL + value: https://thanos-querier.openshift-monitoring.svc.cluster.local:9091 + - name: KEPLER-METRIC-NAME + value: kepler_container_joules_total + - name: SUSQL-PROMETHEUS-DATABASE-URL + value: https://thanos-querier.openshift-monitoring.svc.cluster.local:9091 + - name: SUSQL-PROMETHEUS-METRICS-URL + value: http://0.0.0.0:8082 + - name: SAMPLING-RATE + value: "2" + image: + imagePullPolicy: Always + livenessProbe: + httpGet: + path: /healthz + port: 8081 + initialDelaySeconds: 15 + periodSeconds: 20 + name: manager + readinessProbe: + httpGet: + path: /readyz + port: 8081 + initialDelaySeconds: 5 + periodSeconds: 10 + resources: + limits: + cpu: 500m + memory: 128Mi + requests: + cpu: 10m + memory: 64Mi + securityContext: + allowPrivilegeEscalation: false + capabilities: + drop: + - ALL + securityContext: + runAsNonRoot: true + serviceAccountName: susql-operator-controller-manager + terminationGracePeriodSeconds: 10 + permissions: + - rules: + - apiGroups: + - "" + resources: + - configmaps + verbs: + - get + - list + - watch + - create + - update + - patch + - delete + - apiGroups: + - coordination.k8s.io + resources: + - leases + verbs: + - get + - list + - watch + - create + - update + - patch + - delete + - apiGroups: + - "" + resources: + - events + verbs: + - create + - patch + serviceAccountName: susql-operator-controller-manager + strategy: deployment installModes: - supported: true type: OwnNamespace diff --git a/config/manifests/kustomization.yaml b/config/manifests/kustomization.yaml index d6f4bb2..5c3f1bc 100644 --- a/config/manifests/kustomization.yaml +++ b/config/manifests/kustomization.yaml @@ -9,20 +9,19 @@ resources: # [WEBHOOK] To enable webhooks, uncomment all the sections with [WEBHOOK] prefix. # Do NOT uncomment sections with prefix [CERTMANAGER], as OLM does not support cert-manager. # These patches remove the unnecessary "cert" volume and its manager container volumeMount. -#patchesJson6902: -#- target: -# group: apps -# version: v1 -# kind: Deployment -# name: susql-controller-manager -# namespace: system -# patch: |- -# # Remove the manager container's "cert" volumeMount, since OLM will create and mount a set of certs. -# # Update the indices in this path if adding or removing containers/volumeMounts in the manager's Deployment. -# - op: remove - -# path: /spec/template/spec/containers/0/volumeMounts/0 -# # Remove the "cert" volume, since OLM will create and mount a set of certs. -# # Update the indices in this path if adding or removing volumes in the manager's Deployment. -# - op: remove -# path: /spec/template/spec/volumes/0 +patchesJson6902: +- target: + group: apps + version: v1 + kind: Deployment + name: controller-manager + namespace: system + patch: |- + # Remove the manager container's "cert" volumeMount, since OLM will create and mount a set of certs. + # Update the indices in this path if adding or removing containers/volumeMounts in the manager's Deployment. + - op: remove + path: /spec/template/spec/containers/0/volumeMounts/0 + # Remove the "cert" volume, since OLM will create and mount a set of certs. + # Update the indices in this path if adding or removing volumes in the manager's Deployment. + - op: remove + path: /spec/template/spec/volumes/0 diff --git a/config/prometheus/monitor.yaml b/config/prometheus/monitor.yaml index af1496d..2aac024 100644 --- a/config/prometheus/monitor.yaml +++ b/config/prometheus/monitor.yaml @@ -4,23 +4,18 @@ apiVersion: monitoring.coreos.com/v1 kind: ServiceMonitor metadata: labels: - control-plane: susql-controller-manager app.kubernetes.io/name: servicemonitor - app.kubernetes.io/instance: susql-controller-manager-metrics-monitor + app.kubernetes.io/instance: controller-manager-metrics-monitor app.kubernetes.io/component: metrics app.kubernetes.io/created-by: susql-operator app.kubernetes.io/part-of: susql-operator app.kubernetes.io/managed-by: kustomize - name: susql-controller-manager-metrics-monitor + name: controller-manager-metrics-monitor namespace: system spec: endpoints: - - path: /metrics - port: https - scheme: https - bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token - tlsConfig: - insecureSkipVerify: true + - port: metrics selector: matchLabels: - control-plane: susql-controller-manager + app.kubernetes.io/name: service + app.kubernetes.io/part-of: susql-operator diff --git a/config/rbac/auth_proxy_role_binding.yaml b/config/rbac/auth_proxy_role_binding.yaml index b9342f4..e808752 100644 --- a/config/rbac/auth_proxy_role_binding.yaml +++ b/config/rbac/auth_proxy_role_binding.yaml @@ -15,5 +15,5 @@ roleRef: name: proxy-role subjects: - kind: ServiceAccount - name: susql-controller-manager + name: controller-manager namespace: system diff --git a/config/rbac/auth_proxy_service.yaml b/config/rbac/auth_proxy_service.yaml index a5b99ca..c51ab58 100644 --- a/config/rbac/auth_proxy_service.yaml +++ b/config/rbac/auth_proxy_service.yaml @@ -2,20 +2,20 @@ apiVersion: v1 kind: Service metadata: labels: - control-plane: susql-controller-manager app.kubernetes.io/name: service - app.kubernetes.io/instance: susql-controller-manager-metrics-service + app.kubernetes.io/instance: controller-manager-metrics-service app.kubernetes.io/component: kube-rbac-proxy app.kubernetes.io/created-by: susql-operator app.kubernetes.io/part-of: susql-operator app.kubernetes.io/managed-by: kustomize - name: susql-controller-manager-metrics-service + name: controller-manager-metrics-service namespace: system spec: ports: - - name: https - port: 8443 + - name: metrics + port: 8082 protocol: TCP - targetPort: https + targetPort: metrics selector: - control-plane: susql-controller-manager + app.kubernetes.io/instance: controller-manager + app.kubernetes.io/component: manager diff --git a/config/rbac/leader_election_role_binding.yaml b/config/rbac/leader_election_role_binding.yaml index 0226e86..07f3abc 100644 --- a/config/rbac/leader_election_role_binding.yaml +++ b/config/rbac/leader_election_role_binding.yaml @@ -15,5 +15,5 @@ roleRef: name: leader-election-role subjects: - kind: ServiceAccount - name: susql-controller-manager + name: controller-manager namespace: system diff --git a/config/rbac/role_binding.yaml b/config/rbac/role_binding.yaml index 9d83e96..f49d023 100644 --- a/config/rbac/role_binding.yaml +++ b/config/rbac/role_binding.yaml @@ -15,5 +15,5 @@ roleRef: name: manager-role subjects: - kind: ServiceAccount - name: susql-controller-manager + name: controller-manager namespace: system diff --git a/config/rbac/service_account.yaml b/config/rbac/service_account.yaml index 9506110..69e2830 100644 --- a/config/rbac/service_account.yaml +++ b/config/rbac/service_account.yaml @@ -3,10 +3,10 @@ kind: ServiceAccount metadata: labels: app.kubernetes.io/name: serviceaccount - app.kubernetes.io/instance: susql-controller-manager-sa + app.kubernetes.io/instance: controller-manager app.kubernetes.io/component: rbac app.kubernetes.io/created-by: susql-operator app.kubernetes.io/part-of: susql-operator app.kubernetes.io/managed-by: kustomize - name: susql-controller-manager + name: controller-manager namespace: system