https://prefect.io logo
Title
j

John Kang

05/18/2022, 3:25 PM
Hopefully, simple question. I'm having issues setting up Google Cloud storage as the remote storage for prefect 2.0. Any tips on what I should do?
Validation failed! Could not automatically determine credentials. Please set GOOGLE_APPLICATION_CREDENTIALS or
explicitly create credentials and re-run the application. For more information, please see
<https://cloud.google.com/docs/authentication/getting-started>
1
I am using these instructions:
When I try to run
prefect storage create
and use google cloud storage it only gives me the option to specify a bucket name, project name, and name for the storage
nothing about entering in the private key to access the storage
k

Kevin Kho

05/18/2022, 3:30 PM
I think you need the environment variable
GOOGLE_APPLICATION_CREDENTIALS
already defined locally pointing to the
json
file that holds the credentials
a

Anna Geller

05/18/2022, 3:31 PM
@John Kang check this thread
j

John Kang

05/18/2022, 4:21 PM
@Anna Geller Thanks so much! For the second code snippet I think you need to add in
from prefect.blocks.storage import GoogleCloudStorageBlock
a

Anna Geller

05/18/2022, 4:24 PM
yup sure, I cut the imports
this wasn't meant to be a complete tutorial, but good catch 👍