Skip to main content

Module aws_profiles

Module aws_profiles 

Source
Expand description

AWS profiles, read from the files the AWS CLI and SDKs share.

object_store reads only AWS_* environment variables, and Polars reads ~/.aws/credentials with a pattern that takes the first key in the file, whichever profile it belongs to. So datui reads the files itself and hands both libraries explicit keys. Static keys come straight from the files, credential_process is run, and everything else a profile can be (SSO, assume-role, web identity) comes from aws configure export-credentials, so none of it is reimplemented here.

Structs§

Credentials
Keys that sign requests, and when they stop working.
Profile
One profile, merged from the config and credentials files.

Functions§

active_profile
The profile the AWS tools would use with no --profile: AWS_PROFILE, then AWS_DEFAULT_PROFILE, then default.
config_path
The config file: AWS_CONFIG_FILE, else ~/.aws/config.
credentials
The keys for profile: straight from the files, from its credential_process, or from the AWS CLI. Runs commands, so only ever call it from a worker.
credentials_path
The credentials file: AWS_SHARED_CREDENTIALS_FILE, else ~/.aws/credentials.
load
Every profile in the two files, default first, then by name.
parse
Profiles from the text of the config and credentials files.
parse_process_output
The JSON credential_process prints, which aws configure export-credentials --format process prints too.