Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 1 | {{/* |
| 2 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 3 | you may not use this file except in compliance with the License. |
| 4 | You may obtain a copy of the License at |
| 5 | |
| 6 | http://www.apache.org/licenses/LICENSE-2.0 |
| 7 | |
| 8 | Unless required by applicable law or agreed to in writing, software |
| 9 | distributed under the License is distributed on an "AS IS" BASIS, |
| 10 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 11 | See the License for the specific language governing permissions and |
| 12 | limitations under the License. |
| 13 | */}} |
| 14 | |
| 15 | {{- define "libvirtReadinessProbeTemplate" }} |
| 16 | exec: |
| 17 | command: |
| 18 | - bash |
| 19 | - -c |
| 20 | - /usr/bin/virsh list |
| 21 | {{- end }} |
| 22 | {{- define "libvirtLivenessProbeTemplate" }} |
| 23 | exec: |
| 24 | command: |
| 25 | - bash |
| 26 | - -c |
| 27 | - /usr/bin/virsh list |
| 28 | {{- end }} |
| 29 | |
| 30 | {{- define "libvirt.daemonset" }} |
| 31 | {{- $daemonset := index . 0 }} |
| 32 | {{- $configMapName := index . 1 }} |
| 33 | {{- $serviceAccountName := index . 2 }} |
| 34 | {{- $envAll := index . 3 }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 35 | {{- with $envAll }} |
| 36 | |
| 37 | {{- $mounts_libvirt := .Values.pod.mounts.libvirt.libvirt }} |
| 38 | {{- $mounts_libvirt_init := .Values.pod.mounts.libvirt.init_container }} |
| 39 | |
| 40 | --- |
| 41 | apiVersion: apps/v1 |
| 42 | kind: DaemonSet |
| 43 | metadata: |
| 44 | name: libvirt |
| 45 | annotations: |
| 46 | {{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" }} |
| 47 | labels: |
| 48 | {{ tuple $envAll .Chart.Name $daemonset | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 4 }} |
| 49 | spec: |
| 50 | selector: |
| 51 | matchLabels: |
| 52 | {{ tuple $envAll .Chart.Name $daemonset | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 6 }} |
| 53 | {{ tuple $envAll $daemonset | include "helm-toolkit.snippets.kubernetes_upgrades_daemonset" | indent 2 }} |
| 54 | template: |
| 55 | metadata: |
| 56 | labels: |
| 57 | {{ tuple $envAll .Chart.Name $daemonset | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 8 }} |
| 58 | annotations: |
Mohammed Naser | 168acc3 | 2024-01-09 17:15:26 -0500 | [diff] [blame] | 59 | kubectl.kubernetes.io/default-container: libvirt |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 60 | {{- dict "envAll" $envAll "podName" "libvirt-libvirt-default" "containerNames" (list "libvirt") | include "helm-toolkit.snippets.kubernetes_mandatory_access_control_annotation" | indent 8 }} |
| 61 | {{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }} |
| 62 | configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} |
| 63 | configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} |
| 64 | spec: |
| 65 | {{ dict "envAll" $envAll "application" "libvirt" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }} |
| 66 | serviceAccountName: {{ $serviceAccountName }} |
| 67 | nodeSelector: |
| 68 | {{ .Values.labels.agent.libvirt.node_selector_key }}: {{ .Values.labels.agent.libvirt.node_selector_value }} |
okozachenko1203 | d2cd687 | 2023-08-31 19:53:51 +1000 | [diff] [blame] | 69 | {{ if $envAll.Values.pod.tolerations.libvirt.enabled }} |
| 70 | {{ tuple $envAll "libvirt" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }} |
| 71 | {{ end }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 72 | hostNetwork: true |
| 73 | hostPID: true |
| 74 | hostIPC: true |
| 75 | dnsPolicy: {{ .Values.pod.dns_policy }} |
| 76 | initContainers: |
| 77 | {{ tuple $envAll "pod_dependency" $mounts_libvirt_init | include "helm-toolkit.snippets.kubernetes_entrypoint_init_container" | indent 8 }} |
| 78 | {{ dict "envAll" $envAll | include "helm-toolkit.snippets.kubernetes_apparmor_loader_init_container" | indent 8 }} |
| 79 | {{- if .Values.conf.ceph.enabled }} |
| 80 | {{- if empty .Values.conf.ceph.cinder.keyring }} |
| 81 | - name: ceph-admin-keyring-placement |
| 82 | {{ tuple $envAll "ceph_config_helper" | include "helm-toolkit.snippets.image" | indent 10 }} |
| 83 | {{ dict "envAll" $envAll "application" "libvirt" "container" "ceph_admin_keyring_placement" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }} |
| 84 | command: |
| 85 | - /tmp/ceph-admin-keyring.sh |
| 86 | volumeMounts: |
| 87 | - name: pod-tmp |
| 88 | mountPath: /tmp |
| 89 | - name: etcceph |
| 90 | mountPath: /etc/ceph |
| 91 | - name: libvirt-bin |
| 92 | mountPath: /tmp/ceph-admin-keyring.sh |
| 93 | subPath: ceph-admin-keyring.sh |
| 94 | readOnly: true |
| 95 | {{- if empty .Values.conf.ceph.admin_keyring }} |
| 96 | - name: ceph-keyring |
| 97 | mountPath: /tmp/client-keyring |
| 98 | subPath: key |
| 99 | readOnly: true |
| 100 | {{ end }} |
| 101 | {{ end }} |
| 102 | - name: ceph-keyring-placement |
| 103 | {{ tuple $envAll "ceph_config_helper" | include "helm-toolkit.snippets.image" | indent 10 }} |
| 104 | {{ dict "envAll" $envAll "application" "libvirt" "container" "ceph_keyring_placement" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }} |
| 105 | env: |
| 106 | - name: CEPH_CINDER_USER |
| 107 | value: "{{ .Values.conf.ceph.cinder.user }}" |
| 108 | {{- if .Values.conf.ceph.cinder.keyring }} |
| 109 | - name: CEPH_CINDER_KEYRING |
| 110 | value: "{{ .Values.conf.ceph.cinder.keyring }}" |
| 111 | {{ end }} |
| 112 | - name: LIBVIRT_CEPH_CINDER_SECRET_UUID |
| 113 | value: "{{ .Values.conf.ceph.cinder.secret_uuid }}" |
| 114 | command: |
| 115 | - /tmp/ceph-keyring.sh |
| 116 | volumeMounts: |
| 117 | - name: pod-tmp |
| 118 | mountPath: /tmp |
| 119 | - name: etcceph |
| 120 | mountPath: /etc/ceph |
| 121 | - name: libvirt-bin |
| 122 | mountPath: /tmp/ceph-keyring.sh |
| 123 | subPath: ceph-keyring.sh |
| 124 | readOnly: true |
| 125 | - name: ceph-etc |
| 126 | mountPath: /etc/ceph/ceph.conf.template |
| 127 | subPath: ceph.conf |
| 128 | readOnly: true |
| 129 | {{- end }} |
| 130 | containers: |
Mohammed Naser | 168acc3 | 2024-01-09 17:15:26 -0500 | [diff] [blame] | 131 | - name: tls-sidecar |
| 132 | {{ tuple $envAll "libvirt_tls_sidecar" | include "helm-toolkit.snippets.image" | indent 10 }} |
| 133 | {{ tuple $envAll $envAll.Values.pod.resources.libvirt_tls_sidecar | include "helm-toolkit.snippets.kubernetes_resources" | indent 10 }} |
| 134 | {{ dict "envAll" $envAll "application" "libvirt" "container" "libvirt_tls_sidecar" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }} |
| 135 | env: |
| 136 | - name: API_ISSUER_KIND |
| 137 | value: {{ .Values.issuers.libvirt.kind }} |
| 138 | - name: API_ISSUER_NAME |
| 139 | value: {{ .Values.issuers.libvirt.name }} |
| 140 | - name: VNC_ISSUER_KIND |
| 141 | value: {{ .Values.issuers.vencrypt.kind }} |
| 142 | - name: VNC_ISSUER_NAME |
| 143 | value: {{ .Values.issuers.vencrypt.name }} |
| 144 | - name: POD_UID |
| 145 | valueFrom: |
| 146 | fieldRef: |
| 147 | fieldPath: metadata.uid |
| 148 | - name: POD_NAME |
| 149 | valueFrom: |
| 150 | fieldRef: |
| 151 | fieldPath: metadata.name |
| 152 | - name: POD_NAMESPACE |
| 153 | valueFrom: |
| 154 | fieldRef: |
| 155 | fieldPath: metadata.namespace |
| 156 | - name: POD_IP |
| 157 | valueFrom: |
| 158 | fieldRef: |
| 159 | fieldPath: status.podIP |
| 160 | volumeMounts: |
| 161 | - name: etc-pki-qemu |
| 162 | mountPath: /etc/pki/qemu |
| 163 | - name: etc-pki-ca |
| 164 | mountPath: /etc/pki/CA |
| 165 | - name: etc-pki-libvirt |
| 166 | mountPath: /etc/pki/libvirt |
| 167 | - name: etc-pki-libvirt-vnc |
| 168 | mountPath: /etc/pki/libvirt-vnc |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 169 | - name: libvirt |
| 170 | {{ tuple $envAll "libvirt" | include "helm-toolkit.snippets.image" | indent 10 }} |
| 171 | {{ tuple $envAll $envAll.Values.pod.resources.libvirt | include "helm-toolkit.snippets.kubernetes_resources" | indent 10 }} |
| 172 | {{ dict "envAll" $envAll "application" "libvirt" "container" "libvirt" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 173 | env: |
okozachenko1203 | d2cd687 | 2023-08-31 19:53:51 +1000 | [diff] [blame] | 174 | {{- if .Values.conf.ceph.enabled }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 175 | - name: CEPH_CINDER_USER |
| 176 | value: "{{ .Values.conf.ceph.cinder.user }}" |
| 177 | {{- if .Values.conf.ceph.cinder.keyring }} |
| 178 | - name: CEPH_CINDER_KEYRING |
| 179 | value: "{{ .Values.conf.ceph.cinder.keyring }}" |
| 180 | {{ end }} |
| 181 | - name: LIBVIRT_CEPH_CINDER_SECRET_UUID |
| 182 | value: "{{ .Values.conf.ceph.cinder.secret_uuid }}" |
okozachenko1203 | d2cd687 | 2023-08-31 19:53:51 +1000 | [diff] [blame] | 183 | {{ end }} |
| 184 | {{- if .Values.conf.ceph.cinder.external_ceph.enabled }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 185 | - name: EXTERNAL_CEPH_CINDER_USER |
| 186 | value: "{{ .Values.conf.ceph.cinder.external_ceph.user }}" |
| 187 | - name: LIBVIRT_EXTERNAL_CEPH_CINDER_SECRET_UUID |
| 188 | value: "{{ .Values.conf.ceph.cinder.external_ceph.secret_uuid }}" |
| 189 | {{ end }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 190 | {{ dict "envAll" . "component" "libvirt" "container" "libvirt" "type" "readiness" "probeTemplate" (include "libvirtReadinessProbeTemplate" . | fromYaml) | include "helm-toolkit.snippets.kubernetes_probe" | indent 10 }} |
| 191 | {{ dict "envAll" . "component" "libvirt" "container" "libvirt" "type" "liveness" "probeTemplate" (include "libvirtLivenessProbeTemplate" . | fromYaml) | include "helm-toolkit.snippets.kubernetes_probe" | indent 10 }} |
| 192 | command: |
| 193 | - /tmp/libvirt.sh |
| 194 | lifecycle: |
Mohammed Naser | 168acc3 | 2024-01-09 17:15:26 -0500 | [diff] [blame] | 195 | postStart: |
| 196 | exec: |
| 197 | command: |
| 198 | - /tmp/wait-for-libvirt.sh |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 199 | preStop: |
| 200 | exec: |
| 201 | command: |
| 202 | - bash |
| 203 | - -c |
| 204 | - |- |
| 205 | kill $(cat /var/run/libvirtd.pid) |
| 206 | volumeMounts: |
okozachenko1203 | 14e3801 | 2023-09-01 01:40:19 +1000 | [diff] [blame] | 207 | - name: etc-pki-qemu |
| 208 | mountPath: /etc/pki/qemu |
Mohammed Naser | 168acc3 | 2024-01-09 17:15:26 -0500 | [diff] [blame] | 209 | - name: etc-pki-ca |
| 210 | mountPath: /etc/pki/CA |
| 211 | - name: etc-pki-libvirt |
| 212 | mountPath: /etc/pki/libvirt |
| 213 | - name: etc-pki-libvirt-vnc |
| 214 | mountPath: /etc/pki/libvirt-vnc |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 215 | - name: pod-tmp |
| 216 | mountPath: /tmp |
| 217 | - name: libvirt-bin |
| 218 | mountPath: /tmp/libvirt.sh |
| 219 | subPath: libvirt.sh |
| 220 | readOnly: true |
Mohammed Naser | 168acc3 | 2024-01-09 17:15:26 -0500 | [diff] [blame] | 221 | - name: libvirt-bin |
| 222 | mountPath: /tmp/wait-for-libvirt.sh |
| 223 | subPath: wait-for-libvirt.sh |
| 224 | readOnly: true |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 225 | - name: libvirt-etc |
| 226 | mountPath: /etc/libvirt/libvirtd.conf |
| 227 | subPath: libvirtd.conf |
| 228 | readOnly: true |
| 229 | - name: libvirt-etc |
| 230 | mountPath: /etc/libvirt/qemu.conf |
| 231 | subPath: qemu.conf |
| 232 | readOnly: true |
| 233 | - name: etc-libvirt-qemu |
| 234 | mountPath: /etc/libvirt/qemu |
| 235 | - mountPath: /lib/modules |
| 236 | name: libmodules |
| 237 | readOnly: true |
| 238 | - name: var-lib-libvirt |
| 239 | mountPath: /var/lib/libvirt |
| 240 | {{- if or ( gt .Capabilities.KubeVersion.Major "1" ) ( ge .Capabilities.KubeVersion.Minor "10" ) }} |
| 241 | mountPropagation: Bidirectional |
| 242 | {{- end }} |
| 243 | - name: var-lib-nova |
| 244 | mountPath: /var/lib/nova |
| 245 | {{- if or ( gt .Capabilities.KubeVersion.Major "1" ) ( ge .Capabilities.KubeVersion.Minor "10" ) }} |
| 246 | mountPropagation: Bidirectional |
| 247 | {{- end }} |
| 248 | - name: run |
| 249 | mountPath: /run |
| 250 | - name: dev |
| 251 | mountPath: /dev |
| 252 | - name: cgroup |
| 253 | mountPath: /sys/fs/cgroup |
| 254 | - name: logs |
| 255 | mountPath: /var/log/libvirt |
| 256 | - name: machine-id |
| 257 | mountPath: /etc/machine-id |
| 258 | readOnly: true |
| 259 | {{- if .Values.conf.ceph.enabled }} |
| 260 | - name: etcceph |
| 261 | mountPath: /etc/ceph |
| 262 | {{- if or ( gt .Capabilities.KubeVersion.Major "1" ) ( ge .Capabilities.KubeVersion.Minor "10" ) }} |
| 263 | mountPropagation: Bidirectional |
| 264 | {{- end }} |
| 265 | {{- if empty .Values.conf.ceph.cinder.keyring }} |
| 266 | - name: ceph-keyring |
| 267 | mountPath: /tmp/client-keyring |
| 268 | subPath: key |
| 269 | readOnly: true |
| 270 | {{- end }} |
okozachenko1203 | d2cd687 | 2023-08-31 19:53:51 +1000 | [diff] [blame] | 271 | {{- end }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 272 | {{- if .Values.conf.ceph.cinder.external_ceph.enabled }} |
| 273 | - name: external-ceph-keyring |
| 274 | mountPath: /tmp/external-ceph-client-keyring |
| 275 | subPath: key |
| 276 | readOnly: true |
| 277 | {{- end }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 278 | {{ if $mounts_libvirt.volumeMounts }}{{ toYaml $mounts_libvirt.volumeMounts | indent 12 }}{{ end }} |
okozachenko1203 | d2cd687 | 2023-08-31 19:53:51 +1000 | [diff] [blame] | 279 | {{- if .Values.pod.sidecars.libvirt_exporter }} |
| 280 | - name: libvirt-exporter |
| 281 | {{ tuple $envAll "libvirt_exporter" | include "helm-toolkit.snippets.image" | indent 10 }} |
| 282 | {{ tuple $envAll $envAll.Values.pod.resources.libvirt_exporter | include "helm-toolkit.snippets.kubernetes_resources" | indent 10 }} |
| 283 | {{ dict "envAll" $envAll "application" "libvirt" "container" "libvirt_exporter" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }} |
Oleksandr K. | ad8f45e | 2024-08-09 20:18:09 +0200 | [diff] [blame] | 284 | args: |
| 285 | - "--libvirt.nova" |
okozachenko1203 | d2cd687 | 2023-08-31 19:53:51 +1000 | [diff] [blame] | 286 | ports: |
| 287 | - name: metrics |
| 288 | protocol: TCP |
| 289 | containerPort: {{ tuple "libvirt_exporter" "direct" "metrics" . | include "helm-toolkit.endpoints.endpoint_port_lookup" }} |
| 290 | livenessProbe: |
| 291 | httpGet: |
| 292 | path: / |
| 293 | port: metrics |
| 294 | readinessProbe: |
| 295 | httpGet: |
| 296 | path: / |
| 297 | port: metrics |
| 298 | volumeMounts: |
| 299 | - name: run |
| 300 | mountPath: /run |
| 301 | {{- if or ( gt .Capabilities.KubeVersion.Major "1" ) ( ge .Capabilities.KubeVersion.Minor "10" ) }} |
| 302 | mountPropagation: Bidirectional |
| 303 | {{- end }} |
| 304 | {{- end }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 305 | volumes: |
okozachenko1203 | 14e3801 | 2023-09-01 01:40:19 +1000 | [diff] [blame] | 306 | - name: etc-pki-qemu |
| 307 | hostPath: |
| 308 | path: /etc/pki/qemu |
Mohammed Naser | 168acc3 | 2024-01-09 17:15:26 -0500 | [diff] [blame] | 309 | - name: etc-pki-ca |
| 310 | emptyDir: {} |
| 311 | - name: etc-pki-libvirt |
| 312 | emptyDir: {} |
| 313 | - name: etc-pki-libvirt-vnc |
Yaguang Tang | 6d49981 | 2024-10-22 06:30:54 +0800 | [diff] [blame] | 314 | hostPath: |
| 315 | path: /etc/pki/libvirt-vnc |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 316 | - name: pod-tmp |
| 317 | emptyDir: {} |
| 318 | - name: libvirt-bin |
| 319 | configMap: |
| 320 | name: libvirt-bin |
| 321 | defaultMode: 0555 |
| 322 | - name: libvirt-etc |
| 323 | secret: |
| 324 | secretName: {{ $configMapName }} |
| 325 | defaultMode: 0444 |
| 326 | {{- if .Values.conf.ceph.enabled }} |
| 327 | - name: etcceph |
| 328 | hostPath: |
| 329 | path: /var/lib/openstack-helm/compute/libvirt |
| 330 | - name: ceph-etc |
| 331 | configMap: |
| 332 | name: {{ .Values.ceph_client.configmap }} |
| 333 | defaultMode: 0444 |
| 334 | {{- if empty .Values.conf.ceph.cinder.keyring }} |
| 335 | - name: ceph-keyring |
| 336 | secret: |
| 337 | secretName: {{ .Values.ceph_client.user_secret_name }} |
| 338 | {{ end }} |
okozachenko1203 | d2cd687 | 2023-08-31 19:53:51 +1000 | [diff] [blame] | 339 | {{ end }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 340 | {{- if .Values.conf.ceph.cinder.external_ceph.enabled }} |
| 341 | - name: external-ceph-keyring |
| 342 | secret: |
| 343 | secretName: {{ .Values.conf.ceph.cinder.external_ceph.user_secret_name }} |
| 344 | {{ end }} |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 345 | - name: libmodules |
| 346 | hostPath: |
| 347 | path: /lib/modules |
| 348 | - name: var-lib-libvirt |
| 349 | hostPath: |
| 350 | path: /var/lib/libvirt |
| 351 | - name: var-lib-nova |
| 352 | hostPath: |
| 353 | path: /var/lib/nova |
| 354 | - name: run |
| 355 | hostPath: |
| 356 | path: /run |
| 357 | - name: dev |
| 358 | hostPath: |
| 359 | path: /dev |
| 360 | - name: logs |
| 361 | hostPath: |
| 362 | path: /var/log/libvirt |
| 363 | - name: cgroup |
| 364 | hostPath: |
| 365 | path: /sys/fs/cgroup |
| 366 | - name: machine-id |
| 367 | hostPath: |
| 368 | path: /etc/machine-id |
| 369 | - name: etc-libvirt-qemu |
| 370 | hostPath: |
| 371 | path: /etc/libvirt/qemu |
Mohammed Naser | f3f59a7 | 2023-01-15 21:02:04 -0500 | [diff] [blame] | 372 | {{ dict "envAll" $envAll "component" "libvirt" "requireSys" true | include "helm-toolkit.snippets.kubernetes_apparmor_volumes" | indent 8 }} |
| 373 | {{ if $mounts_libvirt.volumes }}{{ toYaml $mounts_libvirt.volumes | indent 8 }}{{ end }} |
| 374 | {{- end }} |
| 375 | {{- end }} |
| 376 | |
| 377 | {{- if .Values.manifests.daemonset_libvirt }} |
| 378 | |
| 379 | {{- $envAll := . }} |
| 380 | {{- $daemonset := "libvirt" }} |
| 381 | {{- $configMapName := "libvirt-etc" }} |
| 382 | {{- $serviceAccountName := "libvirt" }} |
| 383 | |
| 384 | {{- $dependencyOpts := dict "envAll" $envAll "dependencyMixinParam" $envAll.Values.network.backend "dependencyKey" "libvirt" -}} |
| 385 | {{- $_ := include "helm-toolkit.utils.dependency_resolver" $dependencyOpts | toString | fromYaml }} |
| 386 | |
| 387 | {{ tuple $envAll "pod_dependency" $serviceAccountName | include "helm-toolkit.snippets.kubernetes_pod_rbac_serviceaccount" }} |
| 388 | {{- $daemonset_yaml := list $daemonset $configMapName $serviceAccountName . | include "libvirt.daemonset" | toString | fromYaml }} |
| 389 | {{- $configmap_yaml := "libvirt.configmap.etc" }} |
| 390 | {{- list $daemonset $daemonset_yaml $configmap_yaml $configMapName . | include "helm-toolkit.utils.daemonset_overrides" }} |
| 391 | |
| 392 | {{- end }} |