Vault
Bootstrapping Kubernetes auth method
[!IMPORTANT]
Documentation Update: Product documentation, which were located in this repository under/website
, are now located inhashicorp/web-unified-docs
, colocated with all other product documentation. Contributions to this content should be done in theweb-unified-docs
repo, and not this one. Changes made to/website
content in this repo will not be reflected on the developer.hashicorp.com website.
Important Note: This chart is not compatible with Helm 2. Please use Helm 3.6+ with this chart.
In this example, we will walk through how to set up the Kubernetes Auth Method.
This assumes the following commands will be run inside a Vault pod running in Kubernetes.
Exec into the Vault pod:
kubectl exec -it vault-0 -- /bin/sh
If you didn't set server.dev.enabled=true
, you'll need to log in to Vault first using vault login
.
Then run the following commands to configure the Kubernetes Auth Method:
vault auth enable kubernetes
vault write auth/kubernetes/config \
kubernetes_host=https://$KUBERNETES_SERVICE_HOST:$KUBERNETES_SERVICE_PORT
From here you can continue to configure Vault from the Kubernetes Auth Method documentation.