Skip to content

Conversation

@PoeppingT
Copy link
Contributor

If you have no region set in the AWS CLI (doable by removing the 'region' line from .aws/config) the result of aws configure list will contain the string "" for the region, meaning the region is parsed incorrectly in the install script. This leads to an error when trying to run the installer that is potentially difficult for a new user to comprehend.

This commit changes the parsing in the install scripts to also check the configured region against the list of regions using aws ec2 describe-regions. If the configured region does not exist in that list, the installer will prompt the user to configure a valid region.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

If you have no region set in the AWS CLI (doable by removing the
'region' line from `.aws/config`) the result of `aws configure list`
will contain the string "<not set>" for the region, meaning the region
is parsed incorrectly in the install script. This leads to an error when
trying to run the installer that is potentially difficult for a
new user to comprehend.

This commit changes the parsing in the install scripts to also check the
configured region against the list of regions using `aws ec2
describe-regions`. If the configured region does not exist in that list,
the installer will prompt the user to configure a valid region.
@PoeppingT PoeppingT requested a review from brtrvn September 13, 2022 22:58
Copy link
Contributor

@brtrvn brtrvn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@brtrvn brtrvn merged commit b5f3f0c into awslabs:main Sep 14, 2022
@PoeppingT PoeppingT deleted the failfast-install-noregion branch October 10, 2022 17:55
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.

2 participants