File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
src/main/java/com/google/devtools/build/lib/sandbox Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change 3737import com .google .devtools .build .lib .events .Reporter ;
3838import com .google .devtools .build .lib .exec .TreeDeleter ;
3939import com .google .devtools .build .lib .exec .local .LocalEnvProvider ;
40+ import com .google .devtools .build .lib .exec .local .LocalExecutionOptions ;
4041import com .google .devtools .build .lib .exec .local .PosixLocalEnvProvider ;
4142import com .google .devtools .build .lib .profiler .Profiler ;
4243import com .google .devtools .build .lib .profiler .SilentCloseable ;
@@ -103,10 +104,11 @@ public static boolean isSupported(final CommandEnvironment cmdEnv) throws Interr
103104
104105 private static boolean computeIsSupported (CommandEnvironment cmdEnv , Path linuxSandbox )
105106 throws InterruptedException {
107+ LocalExecutionOptions options = cmdEnv .getOptions ().getOptions (LocalExecutionOptions .class );
106108 ImmutableList <String > linuxSandboxArgv =
107109 LinuxSandboxCommandLineBuilder .commandLineBuilder (
108110 linuxSandbox , ImmutableList .of ("/bin/true" ))
109- .setTimeout (Duration . ofSeconds ( 1 ))
111+ .setTimeout (options . getLocalSigkillGraceSeconds ( ))
110112 .build ();
111113 ImmutableMap <String , String > env = ImmutableMap .of ();
112114 Path execRoot = cmdEnv .getExecRoot ();
You can’t perform that action at this time.
0 commit comments