Skip to content

feat(vault/kubernetes): allow configurable token path#1016

Merged
yxxhero merged 4 commits into
helmfile:mainfrom
pgdagenais:configurable-token-path
Feb 26, 2026
Merged

feat(vault/kubernetes): allow configurable token path#1016
yxxhero merged 4 commits into
helmfile:mainfrom
pgdagenais:configurable-token-path

Conversation

@pgdagenais

Copy link
Copy Markdown
Contributor

While trying to use the Kubernetes auth with a Token using Audience I wasn't able to use a custom path for my token.

This merge request allow the user to specify an environment variable to do so.

Thanks!

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support for specifying a custom Kubernetes JWT token file path when using Vault Kubernetes authentication, enabling projected service account tokens (e.g., with custom audiences) to be used with vals.

Changes:

  • Allow overriding the default Kubernetes service account token file path via VAULT_KUBERNETES_JWT_TOKEN_PATH.
  • Improve Vault Kubernetes auth token file error messages to include the path being accessed.
  • Document the new environment variable in the Vault authentication section of the README.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
pkg/providers/vault/vault.go Adds env-var override for Kubernetes JWT token path and improves related error handling/messages.
README.md Documents VAULT_KUBERNETES_JWT_TOKEN_PATH for Vault Kubernetes auth.

@yxxhero

yxxhero commented Feb 24, 2026

Copy link
Copy Markdown
Member

@pgdagenais please fix CI issue.

@pgdagenais pgdagenais force-pushed the configurable-token-path branch from d456fa4 to 078c7e1 Compare February 24, 2026 15:15
@pgdagenais

Copy link
Copy Markdown
Contributor Author

@yxxhero fixed! Please tell me if there is anything else that should be done.

Thanks!

@yxxhero yxxhero requested a review from Copilot February 24, 2026 23:44

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

pkg/providers/vault/vault.go:285

  • Variable name mount_point uses snake_case instead of Go's conventional camelCase. Rename to mountPoint for consistency with Go naming conventions.
			mount_point := os.Getenv("VAULT_KUBERNETES_MOUNT_POINT")

@yxxhero

yxxhero commented Feb 25, 2026

Copy link
Copy Markdown
Member

@pgdagenais please fix lint issue.

Signed-off-by: pdagenais2 <[email protected]>
@pgdagenais

Copy link
Copy Markdown
Contributor Author

@yxxhero I think this should fix the linting issues, very weird since locally I wasn't able to reproduce even tho I was using the same version than your CI. Not sure why this was triggered by my changes even tho it comes from another provider.

@yxxhero

yxxhero commented Feb 26, 2026

Copy link
Copy Markdown
Member

@yxxhero I think this should fix the linting issues, very weird since locally I wasn't able to reproduce even tho I was using the same version than your CI. Not sure why this was triggered by my changes even tho it comes from another provider.

@pgdagenais thanks so much.

@yxxhero yxxhero merged commit 30030d1 into helmfile:main Feb 26, 2026
5 checks passed
@pgdagenais pgdagenais deleted the configurable-token-path branch February 26, 2026 06:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants