-
Notifications
You must be signed in to change notification settings - Fork 275
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Properly create and use default credential (#1818)
* Properly create and use default credential This PR consists of the following changes: - Stopped adding scopes to the default credential when using it to access other non-workspace GCP APIs. Scopes are not needed here. - Started applying scopes to the default credential when using to access Drive and Sheets APIs. - Upgraded Drive access from the deprecated credential lib to the up-to-date one - Switched Sheet access from the exported json credential to the scoped default credential. This PR requires that the affected files be writable to the default service account (project-name@appspot.gserviceaccount.com) of the project. - This is already the case for exported files (premium terms, reserved terms, and domain list). - The registrar sync sheets in alpha, sandbox, and production have been updated with the new permissions. All impacted operations have been tested in alpha. * Properly create and use default credential This PR consists of the following changes: - Added a new method to generate scope-less default credential when using it to access other non-workspace GCP APIs. Scopes are not needed here. - Started to use the new credential in the SecreteManager. - Will migrate other usages to this new credential gradually. - Marked the old DefaultCredential as deprecated. - Started applying scopes to the default credential when using to access Drive and Sheets APIs. - Upgraded Drive access from the deprecated credentials lib - Switched Sheet access from the exported json credential to the scoped default credential. This PR requires that the affected files be writable to the default service account (project-name@appspot.gserviceaccount.com) of the project. - This is already the case for exported files (premium terms, reserved terms, and domain list). - The registrar sync sheets in alpha, sandbox, and production have been updated with the new permissions. All impacted operations have been tested in alpha.
- Loading branch information
Showing
5 changed files
with
63 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters