Can Mimir read secrets from Volume mounts #6148
-
Describe the bugWhen using secrets from volume mount mimir applications not starting Values file: alertmanager:
extraVolumes:
- name: secret-grafana-mimir
secret:
secretName: secret-grafana-mimir
# Extra volume mounts that will be added to the alertmanager container
extraVolumeMounts:
- name: secret-grafana-mimir
mountPath: "/etc/secret"
readOnly: true
mimir:
structuredConfig:
alertmanager_storage:
backend: azure
azure:
## Recplaced the ${} var with the file path
account_name: /etc/secret/MIMIR_STORAGE_ACCOUNT_NAME
account_key: /etc/secret/MIMIR_STORAGE_ACCOUNT_KEY
container_name: mimir-alaertmanager
compactor:
data_dir: "/data"
... if I bash into a container and look at secret files I can see the correct content but I get the following errors for all the services Error from Mimir Alert manager:
Error from Mimir Ingestor
All other services have similar errors (Alert manager, compactor, ingester, querier, querier-frontend, ruler, storage-gateway) To ReproduceSteps to reproduce the behavior:
Expected behaviorExpect each service to read the secrets file and use the contents Environment
Additional ContextLogs are above along with config file |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 10 replies
-
Reading secrets from a file is not supported by Mimir. Have you tried mounting the secrets as environment variables and referring to them with the |
Beta Was this translation helpful? Give feedback.
Reading secrets from a file is not supported by Mimir.
Have you tried mounting the secrets as environment variables and referring to them with the
${ENVIRONMENT_VARIABLE_NAME}
syntax? Would that work for your situation?