Skip to content

Commit

Permalink
fix dict access
Browse files Browse the repository at this point in the history
  • Loading branch information
blink1073 committed Nov 7, 2023
1 parent 9f75202 commit f06c5e4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .evergreen/auth_aws/aws_tester.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,11 @@ def setup_ecs():
with open('/etc/lsb-release') as fid:
text = fid.read()
if 'jammy' in text:
task_definition = CONFIG[get_key('iam_auth_ecs_task_definition_jammy')]
task_definition = CONFIG.get(get_key('iam_auth_ecs_task_definition_jammy'), None)
if task_definition is None:
raise ValueError('Please set "iam_auth_ecs_task_definition_jammy" variable')
elif 'focal' in text:
task_definition = CONFIG[get_key('iam_auth_ecs_task_definition_focal')]
task_definition = CONFIG.get(get_key('iam_auth_ecs_task_definition_focal'), None)
# Fall back to previous task definition for backward compat.
if task_definition is None:
task_definition = CONFIG[get_key('iam_auth_ecs_task_definition')]
Expand Down

0 comments on commit f06c5e4

Please sign in to comment.