Skip to content

Read default region from ~/.aws/config #436

@adam-fowler

Description

@adam-fowler

Steps

  • Add default region to AWSClient.
  • Read environment variable AWS_DEFAULT_REGION or value in ~/.aws/config. Will need to take into account AWS_PROFILE environment variable. Might need to do something to sync with ConfigFileCredentialProvider
  • To ensure this is done before any requests are made, need to do this before the credential provider setup is complete
  • If a service config has no region then should use default region from AWSClient.
  • As service can be created before AWSClient we cannot just copy default region to service. One way to avoid this is add new region useDefault which will use AWSClient default when a request occurs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions