Credential#
- class geodesic.account.credentials.Credential(**credential)[source]#
Credentials to access secure resources such as a cloud storage bucket.
Credentials have a name, type and data. Credentials can be created or deleted but not accessed again except by internal services. This is for security reasons. Credentials are stored using symmetric PGP encryption at rest.
Attributes
data
name
(str) - the name of this credential.
type
(str) - the type of the credential.
uid
(str) - the unique ID for this credential.
Methods
clear
()copy
()create
([ignore_if_exists])Creates a new Credentials.
delete
()from_aws_key_pair
(*, name, aws_access_key_id)Creates new AWS Key Pair Credential.
from_azure_connection_string
(*, name[, ...])Creates new Azure Storage Account Credential.
from_azure_storage_account
(*, name, account_name)Creates new Azure Storage Account Credential.
from_basic_auth
(*, name, username[, password])Creates new Basic Auth Credential.
from_docker_registry
(*, username, host, email)Creates a new Docker Pull Credential for a Docker Registry.
from_gcp_service_account
(*, name[, key])Creates new GCP Service Account Credential.
from_jwt
(*, name[, jwt, token_url, api_key, ...])Creates new JSON Web Token Credential.
from_oauth2_client_credentials
(*, name, ...)Creates new OAuth2 Client Credentials Credential.
from_oauth2_refresh_token
(*, name, ...[, ...])fromkeys
([value])Create a new dictionary with keys from iterable and values set to value.
get
(key[, default])Return the value for key if key is in the dictionary, else default.
items
()keys
()pop
(k[,d])If the key is not found, return the default if given; otherwise, raise a KeyError.
popitem
()Remove and return a (key, value) pair as a 2-tuple.
setdefault
(key[, default])Insert key with a value of default if key is not in the dictionary.
update
(*mapping, **kwargs)values
()