|
| 1 | +# Copyright 2026 Google LLC |
| 2 | +# |
| 3 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | +# you may not use this file except in compliance with the License. |
| 5 | +# You may obtain a copy of the License at |
| 6 | +# |
| 7 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | +# |
| 9 | +# Unless required by applicable law or agreed to in writing, software |
| 10 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | +# See the License for the specific language governing permissions and |
| 13 | +# limitations under the License. |
| 14 | + |
| 15 | +apiVersion: v1 |
| 16 | +kind: ServiceAccount |
| 17 | +metadata: |
| 18 | + annotations: |
| 19 | + cnrm.cloud.google.com/version: 1.153.0 |
| 20 | + iam.gke.io/gcp-service-account: cnrm-system-${NAMESPACE?}@${PROJECT_ID?}.iam.gserviceaccount.com |
| 21 | + labels: |
| 22 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 23 | + cnrm.cloud.google.com/system: "true" |
| 24 | + name: cnrm-controller-manager-${NAMESPACE?} |
| 25 | + namespace: cnrm-system |
| 26 | +--- |
| 27 | +apiVersion: rbac.authorization.k8s.io/v1 |
| 28 | +kind: RoleBinding |
| 29 | +metadata: |
| 30 | + annotations: |
| 31 | + cnrm.cloud.google.com/version: 1.153.0 |
| 32 | + finalizers: |
| 33 | + - configconnector.cnrm.cloud.google.com/finalizer |
| 34 | + labels: |
| 35 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 36 | + cnrm.cloud.google.com/system: "true" |
| 37 | + name: cnrm-admin-binding-${NAMESPACE?} |
| 38 | + namespace: ${NAMESPACE?} |
| 39 | +roleRef: |
| 40 | + apiGroup: rbac.authorization.k8s.io |
| 41 | + kind: ClusterRole |
| 42 | + name: cnrm-admin |
| 43 | +subjects: |
| 44 | +- kind: ServiceAccount |
| 45 | + name: cnrm-controller-manager-${NAMESPACE?} |
| 46 | + namespace: cnrm-system |
| 47 | +--- |
| 48 | +apiVersion: rbac.authorization.k8s.io/v1 |
| 49 | +kind: RoleBinding |
| 50 | +metadata: |
| 51 | + annotations: |
| 52 | + cnrm.cloud.google.com/version: 1.153.0 |
| 53 | + finalizers: |
| 54 | + - configconnector.cnrm.cloud.google.com/finalizer |
| 55 | + labels: |
| 56 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 57 | + cnrm.cloud.google.com/system: "true" |
| 58 | + name: cnrm-manager-ns-binding-${NAMESPACE?} |
| 59 | + namespace: ${NAMESPACE?} |
| 60 | +roleRef: |
| 61 | + apiGroup: rbac.authorization.k8s.io |
| 62 | + kind: ClusterRole |
| 63 | + name: cnrm-manager-ns-role |
| 64 | +subjects: |
| 65 | +- kind: ServiceAccount |
| 66 | + name: cnrm-controller-manager-${NAMESPACE?} |
| 67 | + namespace: cnrm-system |
| 68 | +--- |
| 69 | +apiVersion: rbac.authorization.k8s.io/v1 |
| 70 | +kind: RoleBinding |
| 71 | +metadata: |
| 72 | + annotations: |
| 73 | + cnrm.cloud.google.com/version: 1.153.0 |
| 74 | + labels: |
| 75 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 76 | + cnrm.cloud.google.com/system: "true" |
| 77 | + name: cnrm-manager-ns-binding-${NAMESPACE?} |
| 78 | + namespace: cnrm-system |
| 79 | +roleRef: |
| 80 | + apiGroup: rbac.authorization.k8s.io |
| 81 | + kind: ClusterRole |
| 82 | + name: cnrm-manager-ns-role |
| 83 | +subjects: |
| 84 | +- kind: ServiceAccount |
| 85 | + name: cnrm-controller-manager-${NAMESPACE?} |
| 86 | + namespace: cnrm-system |
| 87 | +--- |
| 88 | +apiVersion: rbac.authorization.k8s.io/v1 |
| 89 | +kind: ClusterRoleBinding |
| 90 | +metadata: |
| 91 | + annotations: |
| 92 | + cnrm.cloud.google.com/version: 1.153.0 |
| 93 | + labels: |
| 94 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 95 | + cnrm.cloud.google.com/system: "true" |
| 96 | + name: cnrm-manager-cluster-binding-${NAMESPACE?} |
| 97 | +roleRef: |
| 98 | + apiGroup: rbac.authorization.k8s.io |
| 99 | + kind: ClusterRole |
| 100 | + name: cnrm-manager-cluster-role |
| 101 | +subjects: |
| 102 | +- kind: ServiceAccount |
| 103 | + name: cnrm-controller-manager-${NAMESPACE?} |
| 104 | + namespace: cnrm-system |
| 105 | +--- |
| 106 | +apiVersion: v1 |
| 107 | +kind: Service |
| 108 | +metadata: |
| 109 | + annotations: |
| 110 | + cnrm.cloud.google.com/version: 1.153.0 |
| 111 | + prometheus.io/port: "8888" |
| 112 | + prometheus.io/scrape: "true" |
| 113 | + labels: |
| 114 | + cnrm.cloud.google.com/monitored: "true" |
| 115 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 116 | + cnrm.cloud.google.com/system: "true" |
| 117 | + name: cnrm-manager-${NAMESPACE?} |
| 118 | + namespace: cnrm-system |
| 119 | +spec: |
| 120 | + ports: |
| 121 | + - name: controller-manager |
| 122 | + port: 443 |
| 123 | + - name: metrics |
| 124 | + port: 8888 |
| 125 | + selector: |
| 126 | + cnrm.cloud.google.com/component: cnrm-controller-manager |
| 127 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 128 | + cnrm.cloud.google.com/system: "true" |
| 129 | +--- |
| 130 | +apiVersion: apps/v1 |
| 131 | +kind: StatefulSet |
| 132 | +metadata: |
| 133 | + annotations: |
| 134 | + cnrm.cloud.google.com/version: 1.153.0 |
| 135 | + labels: |
| 136 | + cnrm.cloud.google.com/component: cnrm-controller-manager |
| 137 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 138 | + cnrm.cloud.google.com/system: "true" |
| 139 | + name: cnrm-controller-manager-${NAMESPACE?} |
| 140 | + namespace: cnrm-system |
| 141 | +spec: |
| 142 | + selector: |
| 143 | + matchLabels: |
| 144 | + cnrm.cloud.google.com/component: cnrm-controller-manager |
| 145 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 146 | + cnrm.cloud.google.com/system: "true" |
| 147 | + serviceName: cnrm-manager-${NAMESPACE?} |
| 148 | + template: |
| 149 | + metadata: |
| 150 | + annotations: |
| 151 | + cnrm.cloud.google.com/version: 1.153.0 |
| 152 | + labels: |
| 153 | + cnrm.cloud.google.com/component: cnrm-controller-manager |
| 154 | + cnrm.cloud.google.com/scoped-namespace: ${NAMESPACE?} |
| 155 | + cnrm.cloud.google.com/system: "true" |
| 156 | + spec: |
| 157 | + containers: |
| 158 | + - args: |
| 159 | + - --scoped-namespace=${NAMESPACE?} |
| 160 | + - --prometheus-scrape-endpoint=:8888 |
| 161 | + command: |
| 162 | + - /configconnector/manager |
| 163 | + env: |
| 164 | + - name: GOMEMLIMIT |
| 165 | + value: 460MiB |
| 166 | + image: gcr.io/gke-release/cnrm/controller:1.153.0 |
| 167 | + imagePullPolicy: Always |
| 168 | + name: manager |
| 169 | + ports: |
| 170 | + - containerPort: 23232 |
| 171 | + readinessProbe: |
| 172 | + httpGet: |
| 173 | + path: /ready |
| 174 | + port: 23232 |
| 175 | + initialDelaySeconds: 7 |
| 176 | + periodSeconds: 3 |
| 177 | + resources: |
| 178 | + limits: |
| 179 | + memory: 512Mi |
| 180 | + requests: |
| 181 | + cpu: 100m |
| 182 | + memory: 512Mi |
| 183 | + securityContext: |
| 184 | + allowPrivilegeEscalation: false |
| 185 | + privileged: false |
| 186 | + runAsNonRoot: true |
| 187 | + runAsUser: 1000 |
| 188 | + enableServiceLinks: false |
| 189 | + serviceAccountName: cnrm-controller-manager-${NAMESPACE?} |
| 190 | + terminationGracePeriodSeconds: 10 |
0 commit comments