stackstorm-k8s
stackstorm-k8s copied to clipboard
Use Secret for `st2.docker.conf` instead of ConfigMap
Here all these credentials are stored in ConfigMap
Doesn't it make more sense to use Secret since this contains credentials.
This is supported via st2.existingConfigSecret. You create a secret with your st2.conf contents, and then pass that secret name to the chart. It then gets mounted like this:
https://github.com/StackStorm/stackstorm-k8s/blob/fabbea9fb89bce6d093ad718def3e28fcfc47c5e/templates/_helpers.tpl#L167-L171
https://github.com/StackStorm/stackstorm-k8s/blob/fabbea9fb89bce6d093ad718def3e28fcfc47c5e/templates/_helpers.tpl#L177-L181
The value is described here: https://github.com/StackStorm/stackstorm-k8s/blob/fabbea9fb89bce6d093ad718def3e28fcfc47c5e/values.yaml#L112-L116
Does that resolve your concerns?
Can we add this to docs please?
I'm using the existingConfig and now I have a secret called st2-secrets-conf that contains the DB / LDAP / RabbitMQ connection info and also a configMap called
And I think that the only reason I don't have Mongo connection info there as well is that I'm not using the mongo chart.
imo there should be a way to force the installation to only accept credentials from secrets.