View Source aws_credentials_file (aws_credentials v0.3.2)

This provider reads the credentials and config files for the Amazon CLI tools. This format is documented here but an example might look like:

~/.aws/credentials

  [default]
  aws_access_key_id = AKIAIOSFODNN7EXAMPLE
  aws_secret_access_key = wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
  aws_session_token = wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLETOKEN
  

~/.aws/config

  [default]
  region = us-east-1
  
Environment parameters:
  • <<"credentials_path">> - this is the base path to the both CLI configuration files. And based on this path, credentials file should exist and config file is optional. By default this is ~/.aws/
  • <<"profile">> - this is the desired profile to use in the credentials file. By default this is <<"default">>

Summary

Functions

-spec fetch(aws_credentials_provider:options()) ->
               {error, any()} | {ok, aws_credentials:credentials(), infinity}.