mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 04:06:03 +00:00
Allow fetching bootstrap-kubeconfig from VM metadata
This commit is contained in:
parent
0a567f0990
commit
77c13d6dc7
@ -914,6 +914,9 @@ contexts:
|
||||
name: service-account-context
|
||||
current-context: service-account-context
|
||||
EOF
|
||||
elif [[ "${FETCH_BOOTSTRAP_KUBECONFIG:-false}" == "true" ]]; then
|
||||
echo "Fetching kubelet bootstrap-kubeconfig file from metadata"
|
||||
get-metadata-value "instance/attributes/bootstrap-kubeconfig" >/var/lib/kubelet/bootstrap-kubeconfig
|
||||
else
|
||||
echo "Fetching kubelet kubeconfig file from metadata"
|
||||
get-metadata-value "instance/attributes/kubeconfig" >/var/lib/kubelet/kubeconfig
|
||||
|
Loading…
Reference in New Issue
Block a user