-
Notifications
You must be signed in to change notification settings - Fork 195
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to use Workload Identity Federation and domain-wide delegation to Google Workspace user with googleapiclient
upload to Google Drive
#440
Comments
Hi there @benglewis 👋! Thank you for opening an issue. Our team will triage this as soon as we can. Please take a moment to review the troubleshooting steps which lists common error messages and their resolution steps. |
Hi @benglewis - the error you're getting is because of quota (number of requests per second) to the Drive API. From the debug logs, the domain-wide delegation token was successfully created. To use the token, you need to pull the generated |
Hi @sethvargo , I would greatly appreciate if you can explain with an example how I can "pull the generated Thank you in advance :) |
@sethvargo I figured it out...
That is it :) |
It's an output of the |
Right. The issue I faced was understanding how to use it together with the Python library. My above code shows how I was able to get it to work 🙂 |
TL;DR
I am also struggling with this. I am using the Python
googleapiclient
library to upload files to Google Drive using both GCP's Workload Identity Provider (WIF) and delegation to my Google Workspace user. The delegation seems to fail and instead, the files are uploaded as the service account (to which I already gave access to the folder), but it then gets stuck later on since it does not have sufficient storage space in it's Google Drive allowance. How can I get this work?Here's the contents of upload_to_gdrive.py:
Expected behavior
The files should be uploaded as my Google Workspace user
Observed behavior
The files are uploaded as the Service Account user until the user hits a storage limit (I have given the service account permissions to the folder and I am uploading large files)
Action YAML
Log output
Additional information
No response
The text was updated successfully, but these errors were encountered: