Skip to content

Commit

Permalink
Allow adding extra volumes to openstack-exporter deployment
Browse files Browse the repository at this point in the history
credit to the original author: Ondrej Vasko <o.vasko@pan-net.eu>
ref: openstack-exporter#11

Signed-off-by: Matej Feder <matej.feder@dnation.cloud>
  • Loading branch information
matofeder committed May 14, 2024
1 parent 2d6a0d4 commit 49b52a5
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
10 changes: 8 additions & 2 deletions charts/prometheus-openstack-exporter/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,11 @@ spec:
{{- . | toYaml | nindent 8 }}
{{- end }}
volumeMounts:
- name: openstack-config
mountPath: /etc/openstack
- name: openstack-config
mountPath: /etc/openstack
{{- if .Values.extraVolumeMounts }}
{{- toYaml .Values.extraVolumeMounts | nindent 8 }}
{{- end }}
ports:
- name: metrics
containerPort: 9180
Expand All @@ -46,6 +49,9 @@ spec:
- name: openstack-config
secret:
secretName: openstack-config
{{- if .Values.extraVolumes }}
{{- toYaml .Values.extraVolumes | nindent 6 }}
{{- end }}
{{- with .Values.hostAliases }}
hostAliases:
{{ toYaml . | indent 8 }}
Expand Down
15 changes: 15 additions & 0 deletions charts/prometheus-openstack-exporter/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,21 @@ multicloud:
#commonLabels:
# prometheus.io/monitor: "true"

# Add extra volumes mounted to openstack-exporter deployment
# Useful for mounting CA Certificates
#extraVolumes:
#- name: company-ca
# configMap:
# name: my-company-ca
# items:
# - key: ca
# path: my-company-ca
#
#extraVolumeMounts:
#- mountPath: /etc/ssl/certs/my-company-ca
# name: company-ca
# subPath: my-company-ca

# Generate a secret for clouds.yaml
# Doc: https://github.com/openstack-exporter/openstack-exporter#openstack-configuration
clouds_yaml_config: |
Expand Down

0 comments on commit 49b52a5

Please sign in to comment.