Use provided docker builder worker for github PR tasks.

This commit is contained in:
Josh Matthews 2019-03-26 17:44:14 -04:00
parent f45bea7e7c
commit 03f79b241c
2 changed files with 4 additions and 3 deletions

View file

@ -75,6 +75,7 @@ def main(task_for):
elif task_for == "github-pull-request": elif task_for == "github-pull-request":
CONFIG.treeherder_repository_name = "servo-prs" CONFIG.treeherder_repository_name = "servo-prs"
CONFIG.index_read_only = True CONFIG.index_read_only = True
CONFIG.docker_image_build_worker_type = None
# We want the merge commit that GitHub creates for the PR. # We want the merge commit that GitHub creates for the PR.
# The event does contain a `pull_request.merge_commit_sha` key, but it is wrong: # The event does contain a `pull_request.merge_commit_sha` key, but it is wrong:
@ -625,7 +626,7 @@ def macos_build_task(name):
CONFIG.task_name_template = "Servo: %s" CONFIG.task_name_template = "Servo: %s"
CONFIG.index_prefix = "project.servo.servo" CONFIG.index_prefix = "project.servo.servo"
CONFIG.docker_image_buil_worker_type = "servo-docker-worker" CONFIG.docker_image_build_worker_type = "servo-docker-worker"
CONFIG.docker_images_expire_in = build_dependencies_artifacts_expire_in CONFIG.docker_images_expire_in = build_dependencies_artifacts_expire_in
CONFIG.repacked_msi_files_expire_in = build_dependencies_artifacts_expire_in CONFIG.repacked_msi_files_expire_in = build_dependencies_artifacts_expire_in

View file

@ -41,7 +41,7 @@ class Config:
self.index_read_only = False self.index_read_only = False
self.scopes_for_all_subtasks = [] self.scopes_for_all_subtasks = []
self.routes_for_all_subtasks = [] self.routes_for_all_subtasks = []
self.docker_image_buil_worker_type = None self.docker_image_build_worker_type = None
self.docker_images_expire_in = "1 month" self.docker_images_expire_in = "1 month"
self.repacked_msi_files_expire_in = "1 month" self.repacked_msi_files_expire_in = "1 month"
self.treeherder_repository_name = None self.treeherder_repository_name = None
@ -723,7 +723,7 @@ class DockerWorkerTask(UnixTaskMixin, Task):
image_build_task = ( image_build_task = (
DockerWorkerTask("Docker image: " + image_name) DockerWorkerTask("Docker image: " + image_name)
.with_worker_type(CONFIG.docker_image_buil_worker_type or self.worker_type) .with_worker_type(CONFIG.docker_image_build_worker_type or self.worker_type)
.with_max_run_time_minutes(30) .with_max_run_time_minutes(30)
.with_index_and_artifacts_expire_in(CONFIG.docker_images_expire_in) .with_index_and_artifacts_expire_in(CONFIG.docker_images_expire_in)
.with_features("dind") .with_features("dind")