feat(charts/dex): add optional initContainers to deployment.#93
Open
larsla wants to merge 1 commit intodexidp:masterfrom
Open
feat(charts/dex): add optional initContainers to deployment.#93larsla wants to merge 1 commit intodexidp:masterfrom
larsla wants to merge 1 commit intodexidp:masterfrom
Conversation
Author
|
Is there anything missing from this PR? Some feedback would be much appreciated. |
Member
|
Looks like it needs a rebase. Other than that, it looks good to me. |
Signed-off-by: Lars Larsson <github@lars.dev>
Author
I rebased it now. |
|
Hey, is there something we can do to help make this PR to be merged, so that we are able to dynamically download the CA Certificates for our databases at startup? |
|
I'd like to use a sidecar to connect to Google Cloud SQL for my storage. https://docs.cloud.google.com/sql/docs/mysql/connect-kubernetes-engine#proxy-sidecar-pattern Can we get support for sidecars merged? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
This adds the possibility to configure
initContainersfor the deployment.What this PR does / why we need it
Connecting to Postgres using TLS with a client certificate requires the private key to have permission mode 0600.
We need to store the TLS certificates/keys as a Kubernetes Secret and mount that to the deployment.
That is currently not possible when running the process as non-root since
securityContext.fsGrouponly modifies the group ownership and willchmod g+rthe mounted files, thus makinggithub.com/lib/pqreject the key due to bad permissions.With the help of an
initContainerwe can copy the files from the secret to another volume andchown/chmodthem.This is the method we used with the old
dexhelm chart from thestablerepository and it's been working well for a couple of years.Closes: #9
The suggestions in that issue was to either use a mutating webhook or build a custom image. Neither works in our use case
since the cluster is too restricted to allow mutating webhooks and building a custom image would not solve the issue since
the root cause is in a library used by Dex.
Special notes for your reviewer
Checklist
Chart.yaml(see the contributing guide for details)Chart.yaml(see the contributing guide for details)make docs