-
-
Notifications
You must be signed in to change notification settings - Fork 39
Advice on how to obtain credentials on Google Cloud Run #21
-
Hey there!
I'm just going through getting set up with this package. I am somewhat new to Cloud Run so I'm not 100% familiar with what's defined in the environment or what will and what won't be picked up automatically.
Do I have to explicitly set GOOGLE_APPLICATION_CREDENTIALS
for this library to authenticate correctly, or will things just work TM️ by way of the fact that it's running on Google Cloud Run? I only ask this because I'm not sure how or what to generate for the environment variable otherwise. The documentation linked to explains automatic credential discovery, which would definitely be more convenient than having another environment variable to manage.
Thanks!
cc. @marickvantuil
Beta Was this translation helpful? Give feedback.
All reactions
Hey, first of all, my bad, I somehow missed this message. When running an application from Cloud Run, it will automatically have the correct GOOGLE_APPLICATION_CREDENTIALS
environment configured. But if not, you can set it manually and reference the path to the JSON key file which can be created for a service account. More info about that here: https://cloud.google.com/docs/authentication/getting-started
Hope that helps.
Replies: 1 comment
-
Hey, first of all, my bad, I somehow missed this message. When running an application from Cloud Run, it will automatically have the correct GOOGLE_APPLICATION_CREDENTIALS
environment configured. But if not, you can set it manually and reference the path to the JSON key file which can be created for a service account. More info about that here: https://cloud.google.com/docs/authentication/getting-started
Hope that helps.
Beta Was this translation helpful? Give feedback.