diff --git a/build/fbcode_builder/getdeps.py b/build/fbcode_builder/getdeps.py index 5f66374f7..03a5f3c04 100755 --- a/build/fbcode_builder/getdeps.py +++ b/build/fbcode_builder/getdeps.py @@ -1021,6 +1021,8 @@ def write_job_for_platform(self, platform, args): # noqa: C901 if build_opts.is_linux(): artifacts = "linux" runs_on = f"ubuntu-{args.ubuntu_version}" + if args.cpu_cores: + runs_on = f"{args.cpu_cores}-core-ubuntu-{args.ubuntu_version}" elif build_opts.is_windows(): artifacts = "windows" runs_on = "windows-2019" @@ -1272,6 +1274,10 @@ def setup_project_cmd_parser(self, parser): parser.add_argument( "--ubuntu-version", default="22.04", help="Version of Ubuntu to use" ) + parser.add_argument( + "--cpu-cores", + help="Number of CPU cores to use (applicable for Linux OS)", + ) parser.add_argument( "--cron", help="Specify that the job runs on a cron schedule instead of on pushes",