hashicorp / hashicorp/vault-helm

Support defining dnsConfig for agent injector

Open
#416 4 comments 1 reaction 0 assignees View on GitHub
enhancement
Dominant language
Shell
Stars
1.3k
Forks
897
Avg merge
3d 1h
Merged PRs (30d)
1

Description

**Is your feature request related to a problem? Please describe.**
I am running an EKS cluster with `cluster domain => cluster.local`. When I am trying to use vault-agent in namespaces other than Vault's namespace, vault-agent cannot resolve Vault's dns thus unable to inject secrets. (Vault Agent seem to only search `ec2.internal` instead of `*.cluster.local`)

I would like to have a way to define own `cluster domain` which appears in Injector's `resolv.conf` so I can continue to use "upstream" Helm chart.

**Describe the solution you'd like**
I would like a way to either:
- to define [dnsConfig](https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-dns-config) for sidecar injector
or
- to add more parameters to `AGENT_INJECT_VAULT_ADDR`, something like:
{{ include "vault.scheme" . }}://{{ template "vault.fullname" . }}.{{ .Release.Namespace }}.svc`{{ if (ne .Values. injector.customDomain "") }}. {{ .Values. injector.customDomain }}{{ end }}`:{{ .Values.server.service.port }}

**Describe alternatives you've considered**
see above

**Additional context**
Add any other context or screenshots about the feature request here.

I am more than happy to create PRs if this feature request is being considered at all.

Contributor guide

Open the contributing guide

Research direction

Start with the upstream Helm chart's agent injector configuration and the AGENT_INJECT_VAULT_ADDR template, then compare the requested dnsConfig behavior with Kubernetes pod DNS configuration. The work is done when the chart exposes a supported way to configure the injector's cluster domain or dnsConfig and the rendered injector pod receives the intended DNS settings.

Written by the indexing model from the issue text.

Assessment

Tech stack
helm, kubernetes
Domain
infrastructure
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.