|
||||||||
This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators. For more information on JIRA, see: http://www.atlassian.com/software/jira |
|
||||||||
This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators. For more information on JIRA, see: http://www.atlassian.com/software/jira |
I think this is caused by the way how the plugin starts slaves. I have a similar issue on Mac OS X slaves, which have a wrong path, but everything is correctly defined in /etc/profile or the Jenkins users profile.
The problem is that the plugin does not start a "login" shell on the remote node, it only does a remote exec through SSH, invoking "bash -c <command>", instead it should do "bash --login -c <command>". I have no idea where to configure the shell settings per node, but in general the shell should be a login one, so it executes all profile's settings. On MacOSX it also misses correct locale settings because of this.
A workaround on mac to get at least the PATH looking correct is to enter the following into "Prefix Start Slave Command": 'eval `/usr/libexec/path_helper -s` && ' (including the trailing space). This makes the process on the slave look like: 'bash -c eval `/usr/libexec/path_helper -s` && cd '/Users/jenkins/jenkins-slave' && java -jar slave.jar'
/usr/libexec/path_helper -s is a utility command (normally used from /etc/profile on mac os x) that builds a "export PATH=" command. It should also be possible to include ". /etc/profile && " into the prefix field.
But I would fix Jenkins SSH slave plugins to create a login shell and make the shell itsself configureable.