Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Cannot deploy to Google Cloud App Engine

Jens Henrik Hosbond
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 11, 2022

 

I'm trying to setup the pipeline to automatically deploy a nodejs application to Google App Engine. I've set the GCP_KEY_FILE_DEV variable in the repository > Deployment > Environment "Development". The variable contains a base64 encoding of the service account file needed to authenticate. But, I keep getting the same error.  See screenshot. Any ideas? Thanks.

pipeline.png

1 answer

0 votes
Igor Stoyanov
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 12, 2022

@Jens Henrik Hosbond hi.Thanks for your question.

Looks like the problem relates to base64 encoding.
Try to test your encoded variable to check access to Google Cloud App Engine in console.

Examples of how to encode:

Linux

1 $ base64 -w 0 < my_ssh_key

Mac OS X

1 $ base64 < my_ssh_key

Regards, Igor.

 

Jens Henrik Hosbond
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 15, 2022

Hi Igor

 

Thank you for your reply. I've tested and validated the base64 encoding. But, it still produces the same error. I've re-checked the permissions on the service account key file and that should be ok.

Any other ideas?

Igor Stoyanov
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 15, 2022

So, for tests you sent request from your console with your base64 encoded file and without using pipe and you received ok response?
Or you received an error even when trying to connect  to Google Cloud App Engine from your console?

Igor Stoyanov
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 15, 2022

Seems i misunderstood you. I thought problem related to pipe.
Did you use this pipe: https://bitbucket.org/atlassian/google-app-engine-deploy/src/master/ ?
If not maybe you should try?

Igor Stoyanov
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 15, 2022

And for your case i think you should do something like this in your pipeline:

echo $GCP_KEY_FILE_DEV | base64 -d > ~/.client-secret.json

gcloud auth activate-service-account --key-file ~/.client-secret.json

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events