File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed
buildbot_effects/buildbot_effects
buildbot_nix/buildbot_nix Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -240,6 +240,9 @@ def run_effects(
240
240
"--bind" ,
241
241
"/nix/var/nix/daemon-socket/socket" ,
242
242
"/nix/var/nix/daemon-socket/socket" ,
243
+ "--ro-bind" ,
244
+ "/bin/sh" ,
245
+ "/bin/sh" ,
243
246
]
244
247
245
248
with NamedTemporaryFile () as tmp :
Original file line number Diff line number Diff line change @@ -25,11 +25,12 @@ class WorkerConfig:
25
25
worker_name : str = field (
26
26
default_factory = lambda : os .environ .get ("WORKER_NAME" , socket .gethostname ())
27
27
)
28
- worker_count_str : str | None = os .environ .get ("WORKER_COUNT" )
29
- if worker_count_str is not None :
30
- worker_count = int ( worker_count_str )
31
- else :
28
+ worker_count_str : str = os .environ .get ("WORKER_COUNT" , "0 " )
29
+ worker_count = int ( worker_count_str )
30
+
31
+ if worker_count == 0 :
32
32
worker_count = multiprocessing .cpu_count ()
33
+
33
34
buildbot_dir : Path = field (
34
35
default_factory = lambda : Path (require_env ("BUILDBOT_DIR" ))
35
36
)
You can’t perform that action at this time.
0 commit comments