What is the problem you are having with rclone?
I'm trying to use rclone for sync bucket from GCP by using an service account access token to avoid using a service account key. I've followed the documentation and It's not working (could not find default credentials error).
Run the command 'rclone version' and share the full output of the command.
rclone v1.68.1
- os/version: debian 12.5 (64 bit)
- os/kernel: 6.1.0-21-amd64 (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.23.1
- go/linking: static
- go/tags: none
Which cloud storage system are you using? (eg Google Drive)
Google cloud Storage
The command you were trying to run (eg rclone copy /tmp remote:tmp
)
$ gcloud auth application-default print-access-token --impersonate-service-account sa-xxxx@project-id.iam.gserviceaccount.com --lifetime=3600
ya29.c.xxxxxxx
$ rclone config update gcp access_token ya29.c.xxxxxxx
$ rclone ls gcp:bkt-xxx -vvv
2025/01/07 18:02:56 DEBUG : rclone: Version "v1.68.1" starting with parameters ["rclone" "ls" "gcp:bkt-xxxxxx" "-vvv"]
2025/01/07 18:02:56 DEBUG : Creating backend with remote "gcp:bkt-xxxxx"
2025/01/07 18:02:56 DEBUG : Using config file from "/home/mcourtois/.config/rclone/rclone.conf"
2025/01/07 18:02:56 CRITICAL: Failed to create file system for "gcp:bkt-xxxx": failed to configure Google Cloud Storage: google: could not find default credentials. See https://cloud.google.com/docs/authentication/external/set-up-adc for more information
Please run 'rclone config redacted' and share the full output. If you get command not found, please make sure to update rclone.
[gcp]
type = google cloud storage
access_token = ya29.c.xxxxx
env_auth = false
A log from the command that you were trying to run with the -vv
flag
2025/01/07 18:02:56 DEBUG : Creating backend with remote "gcp:bkt-xxxxx"
2025/01/07 18:02:56 DEBUG : Using config file from "/home/mcourtois/.config/rclone/rclone.conf"
2025/01/07 18:02:56 CRITICAL: Failed to create file system for "gcp:bkt-xxxx": failed to configure Google Cloud Storage: google: could not find default credentials. See https://cloud.google.com/docs/authentication/external/set-up-adc for more information