Closed alexeyinkin closed 7 months ago
Hey! Yes, that is something we want!
I would love if you opened a PR on it. See #6 for more 🙌
there is a problem with that plugin you mentioned for example, in case you want to use option "use_auth_provider", for cases you use a long term auth. and not you dont want to run the get credentials action again.
use_auth_provider - (Optional) If true, use the Google Cloud auth plugin in kubectl instead of a short-lived access token. The default value is false
.
- name: Set up Cloud SDK
uses: google-github-actions/setup-gcloud@v2
with:
project_id: ${{ env.project }}
install_components: 'gke-gcloud-auth-plugin'
- name: get credentials for the kubectl
uses: google-github-actions/get-gke-credentials@v2
with:
cluster_name: ${{ env.cluster_name }}
location: ${{ env.region }}
project_id: ${{ env.project }}
use_auth_provider: true
will give you an error when trying to "kubectl get po"
Error: Kubernetes cluster unreachable: The gcp auth plugin has been removed.
Please use the "gke-gcloud-auth-plugin" kubectl/client-go credential plugin instead.
This action does the job for me: https://github.com/google-github-actions/get-gke-credentials
Can you mention it on README so people can find it easier?