Skip to content

Commit

Permalink
Fixing reported issues awslabs#171 awslabs#179
Browse files Browse the repository at this point in the history
  • Loading branch information
bsajjan committed Dec 2, 2021
1 parent b8e98ff commit fb1c8ff
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion MWAA/verify_env/verify_env.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ def validation_region(input_region):
'''
session = Session()
mwaa_regions = session.get_available_regions('mwaa')
new_regions = ['sa-east-1', 'ap-northeast-2', 'ap-south-1', 'ca-central-1', 'eu-west-2', 'eu-west-3']
mwaa_regions.extend(new_regions)
if input_region in mwaa_regions:
return input_region
raise argparse.ArgumentTypeError("%s is an invalid REGION value" % input_region)
Expand All @@ -88,7 +90,7 @@ def validation_profile(profile_name):
'''
verify profile name doesn't have path to files or unexpected input
'''
if re.match(r"^[a-zA-Z0-9]*$", profile_name):
if re.match(r"^[a-zA-Z0-9\-]*$", profile_name):
return profile_name
raise argparse.ArgumentTypeError("%s is an invalid profile name value" % profile_name)

Expand Down

0 comments on commit fb1c8ff

Please sign in to comment.