When i am trying to access projects in my google cloud account using
gcloud projects list
always getting the following
<span>Listed 0 items.</span> <span>+ gcloud projects list</span>
So I can't complete the steps - and i can't set the project
and in this step
gcloud config set project $MY_PROJECT
I got
<span>Updated property [core/project].<br></span><span>WARNING: You do not appear to have access to project [#My_PROJECT] or it does not exist.</span><span>+ gcloud config set project #My_PROJECT </span>
The following is steps in my pipeline
- step:
name: Test google auth
image: google/cloud-sdk:latest
script:
- echo $KEY_FILE | base64 --decode --ignore-garbage > ~/google-key.json
- gcloud auth activate-service-account --key-file ~/google-key.json
- gcloud projects list
- gcloud config set project $MY_PROJECT
- gcloud container clusters get-credentials $MY_CLUSTER --region $REGION
services:
- docker
- Is there any missing steps? or prerequists to link bitbucket to my google account?