Created
February 19, 2024 23:02
-
-
Save valentin2105/28f3f4ebf0016a78e3cfdfb8fc092578 to your computer and use it in GitHub Desktop.
curl Kube-API from a pod via service-account
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl https://${KUBERNETES_SERVICE_HOST} \ | |
--header "Authorization: Bearer $(cat /var/run/secrets/kubernetes.io/serviceaccount/token)" \ | |
--cacert /var/run/secrets/kubernetes.io/serviceaccount/ca.crt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment