Module cache

Module cache 

Source
Expand description

Token cache handling (keyring and file-based). Token caching utility.

This stores OAuth tokens securely using the system keyring (by default) or to a file if the GCLOUD_IDENTITY_TOKEN_PATH environment variable is set.

The keyring entry is namespaced under the service gcloud-identity-token and the keyring “username” is extracted from the ID token’s email field.

Functions§

delete_token
Deletes a token from the system keyring.
load_cached_token
Loads a cached token from either a file or the system keyring.
save_token
Saves a token to either a file or the system keyring.