diff --git a/glance/templates/deployment-api.yaml b/glance/templates/deployment-api.yaml index d402eddadd..26ffdf4a38 100644 --- a/glance/templates/deployment-api.yaml +++ b/glance/templates/deployment-api.yaml @@ -37,6 +37,8 @@ httpGet: {{- $serviceAccountName := "glance-api" }} {{ tuple $envAll "api" $serviceAccountName | include "helm-toolkit.snippets.kubernetes_pod_rbac_serviceaccount" }} + +{{- $etcSources := .Values.pod.etcSources.glance_api }} --- apiVersion: apps/v1 kind: Deployment @@ -203,6 +205,9 @@ spec: mountPath: /etc/glance/glance-api.conf subPath: glance-api.conf readOnly: true + - name: glance-etc-snippets + mountPath: /etc/glance/glance.conf.d/ + readOnly: true - name: glance-etc mountPath: /etc/glance/glance-api-uwsgi.ini subPath: glance-api-uwsgi.ini @@ -323,6 +328,14 @@ spec: secret: secretName: glance-etc defaultMode: 0444 + - name: glance-etc-snippets +{{- if $etcSources }} + projected: + sources: +{{ toYaml $etcSources | indent 14 }} +{{- else }} + emptyDir: {} +{{ end }} {{- if eq .Values.storage "pvc" }} - name: glance-images persistentVolumeClaim: diff --git a/glance/values.yaml b/glance/values.yaml index a1ca402a25..d0d8dcdefd 100644 --- a/glance/values.yaml +++ b/glance/values.yaml @@ -908,6 +908,11 @@ pod: glance_db_sync: volumeMounts: volumes: + # -- This allows users to add Kubernetes Projected Volumes to be mounted at /etc/glance/glance.conf.d/ + ## This is a list of projected volume source objects for each deployment/statefulset/daemonset/cronjob + ## https://kubernetes.io/docs/concepts/storage/projected-volumes/ + etcSources: + glance_api: replicas: api: 1 lifecycle: diff --git a/releasenotes/notes/glance-cbd61a1ae1e902b5.yaml b/releasenotes/notes/glance-cbd61a1ae1e902b5.yaml new file mode 100644 index 0000000000..c5a6b5b4a0 --- /dev/null +++ b/releasenotes/notes/glance-cbd61a1ae1e902b5.yaml @@ -0,0 +1,7 @@ +--- +glance: + - | + Allow users to add additional sources to the Projected Volume that is mounted + at /etc/glance/glance.conf.d/ so they may more easily override configs or provide + additional configs for the various services in the chart. +...