Skip to content

For the "kubernetes-university-live" code sample, the google-cloud-cli-gke-gcloud-auth-plugin dependency is not listed in Scylla U #213

@GeoffMontee

Description

@GeoffMontee

When following the instructions to use the "kubernetes-university-live" code sample in Scylla U, a dependency is not listed, which causes a failure.

Steps to reproduce

  1. Install gcloud via the Google Cloud SDK.

  2. Initialize gcloud:

gcloud init
  1. Login via gcloud:
gcloud auth login
  1. Install kubectl.

  2. Install helm.

  3. Clone the repo:

git clone https://github.com/scylladb/scylla-code-samples.git
  1. Change directory:
cd scylla-code-samples/kubernetes-university-live
  1. Set the account and project to environment variables:
export GCP_USER=$(gcloud config list account --format "value(core.account)")   
export GCP_PROJECT=$(gcloud config list project --format "value(core.project)") 
  1. Run the gke.sh script:
./gke.sh --gcp-user "$GCP_USER" -p "$GCP_PROJECT" -c "university-live-demo"

Actual results

A failure occurs due to a missing dependency:

Checking if kubectl is present on the machine...
Checking if helm is present on the machine...
WARNING: The `--enable-stackdriver-kubernetes` flag is deprecated and will be removed in an upcoming release. Please use `--logging` and `--monitoring` instead. For more information, please read: https://cloud.google.com/stackdriver/docs/solutions/gke/installing.
Note: Your Pod address range (`--cluster-ipv4-cidr`) can accommodate at most 1008 node(s).
Creating cluster university-live-demo in us-west1-b... Cluster is being health-checked (master is healthy)...done.               
Created [https://container.googleapis.com/v1/projects/skilled-adapter-452/zones/us-west1-b/clusters/university-live-demo].
To inspect the contents of your cluster, go to: https://console.cloud.google.com/kubernetes/workload_/gcloud/us-west1-b/university-live-demo?project=skilled-adapter-452
CRITICAL: ACTION REQUIRED: gke-gcloud-auth-plugin, which is needed for continued use of kubectl, was not found or is not executable. Install gke-gcloud-auth-plugin for use with kubectl by following https://cloud.google.com/blog/products/containers-kubernetes/kubectl-auth-changes-in-gke
kubeconfig entry generated for university-live-demo.
NAME                  LOCATION    MASTER_VERSION      MASTER_IP      MACHINE_TYPE   NODE_VERSION        NUM_NODES  STATUS
university-live-demo  us-west1-b  1.27.8-gke.1067004  35.233.177.76  n1-standard-8  1.27.8-gke.1067004  2          RUNNING
Creating node pool scylla-pool...done.                                                                                           
Created [https://container.googleapis.com/v1beta1/projects/skilled-adapter-452/zones/us-west1-b/clusters/university-live-demo/nodePools/scylla-pool].
NAME         MACHINE_TYPE   DISK_SIZE_GB  NODE_VERSION
scylla-pool  n1-standard-4  20            1.27.8-gke.1067004
Waiting GKE to UPGRADE_MASTER
Waiting for cluster readiness...
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
Waiting for cluster readiness... 
university-live-demo us-west1-b 1.27.8-gke.1067004 35.233.177.76 n1-standard-8 1.27.8-gke.1067004 8 RECONCILING
Listed 0 items.
Listed 0 items.
university-live-demo  us-west1-b  1.27.8-gke.1067004  35.233.177.76  n1-standard-8  1.27.8-gke.1067004  8          RUNNING
Getting credentials for newly created cluster...
Fetching cluster endpoint and auth data.
CRITICAL: ACTION REQUIRED: gke-gcloud-auth-plugin, which is needed for continued use of kubectl, was not found or is not executable. Install gke-gcloud-auth-plugin for use with kubectl by following https://cloud.google.com/blog/products/containers-kubernetes/kubectl-auth-changes-in-gke
kubeconfig entry generated for university-live-demo.
Setting up GKE RBAC...
error: failed to create clusterrolebinding: Post "https://35.233.177.76/apis/rbac.authorization.k8s.io/v1/clusterrolebindings?fieldManager=kubectl-create&fieldValidation=Strict": getting credentials: exec: executable gke-gcloud-auth-plugin not found

It looks like you are trying to use a client-go credential plugin that is not installed.

To learn more about this feature, consult the documentation available at:
      https://kubernetes.io/docs/reference/access-authn-authz/authentication/#client-go-credential-plugins

Install gke-gcloud-auth-plugin for use with kubectl by following https://cloud.google.com/blog/products/containers-kubernetes/kubectl-auth-changes-in-gke

Expected results

The missing dependency must be installed prior to running gke.sh:

sudo apt install google-cloud-cli-gke-gcloud-auth-plugin

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions