I'm getting Bad credentials for bucket
trying to mount a GCS bucket using gcsfuse. What I've done:
- Created a bucket "mac-gcs-fuse"
- Created a service account in the same project with all storage permissions
- Run the following command
gcsfuse --key-file=/Users/tiagogouvea/Keys/gcp-Storage-Pessoal-mac-gcs-fuse-service-account.json mac-gcs-fuse ~/mac-gcs-fuse
And I got:
Using mount point: /Users/tiagogouvea/mac-gcs-fuse
Opening GCS connection...
Opening bucket...
daemonize.Run: readFromProcess: sub-process: mountWithArgs: mountWithConn: setUpBucket: OpenBucket: Bad credentials for bucket "mac-gcs-fuse". Check the bucket name and your credentials.
I try export GOOGLE_APPLICATION_CREDENTIALS
too but with same error.
What I'm missing? I appreciate any help.
Best Answer
You can try to run by Google Compute Engine instance with scope storage-full configured, then Cloud Storage FUSE can use the Compute Engine built-in service account.
Have you tried with the primitive privileges of the bucket?
Are you sure that your .json file is accessible form the context that you are requesting them?