Skip to content

Commit

Permalink
fix: minor fixes for build system
Browse files Browse the repository at this point in the history
Signed-off-by: Jericho Tolentino <[email protected]>
  • Loading branch information
jericht committed Sep 21, 2023
1 parent cbba4db commit 784a3b1
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 6 deletions.
12 changes: 8 additions & 4 deletions src/deadline_test_fixtures/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,14 @@
BootstrapResources,
DeadlineResources,
bootstrap_resources,
codeartifact,
deadline_client,
deadline_resources,
deploy_job_attachment_resources,
install_service_model,
service_model,
worker,
worker_config,
)
from .job_attachment_manager import JobAttachmentManager
from .models import (
Expand All @@ -38,9 +42,6 @@
"CommandResult",
"DeadlineResources",
"DeadlineClient",
"DeadlineScaffolding",
"DeadlineSubmitter",
"DeadlineJob",
"DeadlineWorker",
"DeadlineWorkerConfiguration",
"DockerContainerWorker",
Expand All @@ -53,14 +54,17 @@
"PipInstall",
"S3Object",
"ServiceModel",
"StubDeadlineClient",
"Queue",
"QueueFleetAssociation",
"TaskStatus",
"bootstrap_resources",
"codeartifact",
"deadline_client",
"deadline_resources",
"deploy_job_attachment_resources",
"install_service_model",
"service_model",
"version",
"worker",
"worker_config",
]
Original file line number Diff line number Diff line change
Expand Up @@ -150,8 +150,12 @@ def __init__(
"Action": [
"s3:HeadObject",
"s3:GetObject",
"s3:ListBucket",
],
"Resource": [
self.bootstrap_bucket.arn,
self.bootstrap_bucket.arn_for_objects(),
],
"Resource": [self.bootstrap_bucket.arn_for_objects()],
},
# Allows access to code artifact
{
Expand Down
2 changes: 1 addition & 1 deletion src/deadline_test_fixtures/deadline/worker.py
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ def _start_worker_agent(self) -> None: # pragma: no cover

LOG.info(f"Sending SSM command to configure Worker agent on instance {self.instance_id}")
cmd_result = self.send_command(
f"cd /home/{self.configuration.user}; . .venv/bin/activate; {configure_worker_command(config=self.configuration)}"
f"cd /home/{self.configuration.user}; . .venv/bin/activate; AWS_DEFAULT_REGION={self.configuration.region} {configure_worker_command(config=self.configuration)}"
)
assert cmd_result.exit_code == 0, f"Failed to configure Worker agent: {cmd_result}"
LOG.info("Successfully configured Worker agent")
Expand Down

0 comments on commit 784a3b1

Please sign in to comment.