Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extra configurations to server config map #504

Open
cucxabong opened this issue Apr 22, 2021 · 2 comments
Open

Extra configurations to server config map #504

cucxabong opened this issue Apr 22, 2021 · 2 comments
Labels
enhancement New feature or request

Comments

@cucxabong
Copy link

Is your feature request related to a problem? Please describe.

Our deployment need some initialization after starting server (such as enable auth backend/import team roles/OIDC/policies...). So it would be handle for us to be able to adding some configuration file into server deployment

Describe the solution you'd like
adding something like below into bottom of server config map spec

{{- if .Values.configuration.data }}
{{ toYaml .Values.configuration.data | indent 2 }}
{{- end }}
@cucxabong cucxabong added the enhancement New feature or request label Apr 22, 2021
@jasonodonnell
Copy link
Contributor

Hi @cucxabong, this is already supported using postStart. The idea is you mount your configuration file using volumes and volumeMounts, then configure postStart.

It does require a little bit of extra configuration on the readiness probe so post start phase works, but I use this in my demo repo here: https://github.com/jasonodonnell/vault-agent-demo/blob/master/values.yaml#L34-L40.

@mprimeaux
Copy link

@jasonodonnell Regarding the chmod +x in your postStart logic, you have the option to set the defaultMode of the volume mount to 0777 as per this to simplify a bit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants