-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
Jenkins 1.556
envinject 1.89
tomcat 7.x
Trivial EnvInject "script contents" throw java.io.IOException: Cannot run program "/bin/sh" (in directory "/home/slavehome/jenkins")
It seems like the script is attempting to run on the master using the slaves jenkinsHome dir.
The script contents run correctly if I add a build tool plugin that provides a tool to the environment.
I've attached a job config that fails and its log, plus a working job and log where I added a build tool. The build tool installation apparently delays the "script content" execution until after the build tool install, which ensures the CWD is actually on the slave and not master when the "script content" is run.