Skip to content

Commit

Permalink
test: Set AWS_ENDPOINT_URL_DEADLINE on Worker
Browse files Browse the repository at this point in the history
Signed-off-by: Charles Moore <[email protected]>
  • Loading branch information
moorec-aws committed Jun 6, 2024
1 parent 6bc4d8f commit 14b3573
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/deadline_test_fixtures/deadline/worker.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@ def configure_worker_command(*, config: DeadlineWorkerConfiguration) -> str: #
cmds.append(
f"runuser -l {config.user} -s /bin/bash -c 'aws configure add-model --service-model file://{config.service_model_path}'"
)

if os.environ.get('AWS_ENDPOINT_URL_DEADLINE'):
LOG.info(f"Using AWS_ENDPOINT_URL_DEADLINE: {os.environ.get('AWS_ENDPOINT_URL_DEADLINE')}")
env = os.environ.get('AWS_ENDPOINT_URL_DEADLINE')
cmds.insert(
0,
f"runuser -l {config.user} -s /bin/bash -c 'echo export AWS_ENDPOINT_URL_DEADLINE={env} >> ~/.bashrc'"
)

return " && ".join(cmds)

Expand Down

0 comments on commit 14b3573

Please sign in to comment.