Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: set default region #142

Merged
merged 22 commits into from
Jun 23, 2023
Merged

fix: set default region #142

merged 22 commits into from
Jun 23, 2023

Conversation

brivu
Copy link
Contributor

@brivu brivu commented Jun 21, 2023

This PR updates the descriptions of the configure_default_region and the configure_profile_region parameters. It also removed the --profile flag from the aws configure set default.region cli command in the configure.sh script. Lastly, it adds testing and validation for configuring both the default region and the profile region.

Currently, there's some confusion regarding the configuration of the default region versus the profile region.

According to the AWS Documentation:

aws configure set default.region:

  • This command sets the default region for the AWS CLI. The specified region will be used by default for all AWS CLI commands unless overridden.
    -The value set using default.region is stored in the AWS CLI configuration file (~/.aws/config), specifically in the [default] section.
    -Example usage: aws configure set default.region us-west-2

aws configure set region:

  • This command sets the region for the current profile in the AWS CLI configuration. The specified region will be used for commands executed under that specific profile.
    -The value set using region is stored in the AWS CLI configuration file (~/.aws/config) within the specific profile section.
    -Example usage: aws configure set region us-west-2 --profile myprofile

In summary, aws configure set default.region sets the default region for all commands executed by the AWS CLI, while aws configure set region sets the region for a specific profile.

@brivu brivu requested a review from a team as a code owner June 21, 2023 20:10
@brivu brivu self-assigned this Jun 21, 2023
@brivu brivu linked an issue Jun 21, 2023 that may be closed by this pull request
src/commands/setup.yml Outdated Show resolved Hide resolved
src/commands/setup.yml Outdated Show resolved Hide resolved
src/scripts/configure.sh Outdated Show resolved Hide resolved
@brivu brivu merged commit bd6b7a1 into master Jun 23, 2023
2 checks passed
@brivu brivu deleted the fix/set-default-region branch June 23, 2023 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

aws-cli/setup for multiple profiles clobbers default region non-obviously
3 participants