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

Allow matching also on pod names #72

Open
randomswdev opened this issue Oct 26, 2019 · 4 comments
Open

Allow matching also on pod names #72

randomswdev opened this issue Oct 26, 2019 · 4 comments
Assignees

Comments

@randomswdev
Copy link

As described in issue #65, a scoped token also includes the name of the pod it has been injected into.

What do you think about about adding an additional configuration parameter that would allow a vault auth role specification to allow matching not only on the kubernetes namespace and service account names, but also on the pod name (possibly using wildcards)?

This would allow to assign roles also based on the pod identity in all those cases when it is not possible to assign different service accounts to different pods, like when building (as in the referenced issue) with the gitlab runner that does assign the same service account to all the spawned build jobs.

If you think this is a reasonable feature to add, I can work to contribute a pull request.

@venky999
Copy link

it would be great to have this.. and is it possible to restrict to pods with specific iam roles ?

@kintarowins
Copy link

kintarowins commented Mar 27, 2020

Please add this feature. Currently, we'd have to create separate service accounts for each pod/deployment. With the additional pod level matching, we'd only need a single service account, greatly reducing the complexity of the setup.

@narg95
Copy link

narg95 commented Oct 1, 2021

I am very interested in this feature, I could help if the feature is wanted and someone guides me in the right direction.
Currently any pod within the same service account is able to read the secrets from all the others.
This feature will provide a more granular access control to vault secrets at the pod level.

@narg95
Copy link

narg95 commented Oct 1, 2021

In case of grouped pods (deployments, daemon-sets, statefull-sets) pods should have access to the same secrets, therefore this feature should also allow setting a prefix to match the pod group.

@imthaghost imthaghost self-assigned this Oct 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants