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

Add support for creating property sources from volume-mounted Kubernetes ConfigMaps and Secrets #19990

Closed
mbhave opened this issue Jan 30, 2020 · 1 comment
Assignees
Labels
theme: config-data Issues related to the configuration theme theme: kubernetes type: enhancement A general enhancement
Milestone

Comments

@mbhave
Copy link
Contributor

mbhave commented Jan 30, 2020

This issue addresses the case where configmaps are not mounted as as an application.properties (or yml) file. For secrets, we need to consider things like if the secret changes, what happens to configuration that has been created using that secret.

@mbhave mbhave added this to the 2.3.x milestone Jan 30, 2020
@mbhave mbhave added the type: enhancement A general enhancement label Jan 30, 2020
@mbhave mbhave added the status: pending-design-work Needs design work before any code can be developed label Feb 28, 2020
@markpollack
Copy link
Member

markpollack commented Apr 14, 2020

I think it is out of scope for Boot to get involved with the lifecycle of changing a secret value. AFAIK, Boot does not handle the case of a change in a configmap that is loaded by ConfigFileApplicationListener. ( #19909 ) There are several tools and approaches to handle this (kustomize with secret/configmap generators) or a custom controller (https://github.com/stakater/Reloader ) that end up restarting the pod. Watching the filesystem where the secrets are mounted doesn't feel like the right solution either, as it would end up competing with these other more well known approaches. I think the scope of this issue should be reading the secrets mounted on the filesystem in one or more directories under a common root, e.g. /secrets Each filename is the property key and the contents are the value. Perhaps a class such as KubernetesSecretFileApplicationListener that contains that logic to create the property sources from the secrets mounted on the filesystem. Mounting secrets on the filesystem is considered the best practice (vs. using environment variables)

@philwebb philwebb modified the milestones: 2.3.x, 2.x Apr 17, 2020
@mbhave mbhave self-assigned this Apr 27, 2020
@philwebb philwebb modified the milestones: 2.x, 2.4.x Jun 5, 2020
@philwebb philwebb added theme: config-data Issues related to the configuration theme theme: kubernetes and removed theme: kubernetes labels Jun 5, 2020
@philwebb philwebb self-assigned this Jul 22, 2020
@philwebb philwebb modified the milestones: 2.4.x, 2.4.0-M2 Jul 23, 2020
@philwebb philwebb removed the status: pending-design-work Needs design work before any code can be developed label Mar 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
theme: config-data Issues related to the configuration theme theme: kubernetes type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

4 participants