10Create bazel_build task_driver. This should rarely need to change, so by putting it into
11CIPD, we should reduce build latency by removing the need for the BuildTaskDrivers job.
12That job *is* idempotent, so Swarming does eventually deduplicate it sometimes (but not
13after a usually unrelated change to something in //bazel), but skipping the step is faster.
22FILE_DIR = os.path.dirname(os.path.abspath(__file__))
23SKIA_ROOT_DIR = os.path.realpath(os.path.join(FILE_DIR, os.pardir, os.pardir, os.pardir, os.pardir))
26 """Compiles the task driver using bazel, which is presumed to be on PATH """
27 out = subprocess.check_output([
28 "bazel",
"build",
"//infra/bots/task_drivers/bazel_build",
29 "--platforms=@io_bazel_rules_go//go/toolchain:linux_amd64",
32 path_to_binary = os.path.join(SKIA_ROOT_DIR,
'bazel-bin',
'infra',
'bots',
'task_drivers',
33 'bazel_build',
'bazel_build_',
'bazel_build')
34 shutil.copy(path_to_binary, target_dir)
38 parser = argparse.ArgumentParser()
39 parser.add_argument(
'--target_dir',
'-t', required=
True)
40 args = parser.parse_args()
44if __name__ ==
'__main__':
def create_asset(target_dir)
def print(*args, **kwargs)