envinject plugin - how to set up for specific slave nodes

58 views
Skip to first unread message

Mark Sinclair

unread,
Feb 13, 2015, 6:10:19 PM2/13/15
to jenkins...@googlegroups.com
I've been using envinject for specific jobs that need it and it works great.

Now I have several slaves and each slave runs a particular type of job.  I want to setup an envinject file for all jobs running on that slave.  I see a place to configure it in:
Manage Jenkins -> Manage Nodes -> Configure Node -> Prepare jobs environment / Properties File Path.

I've specified an absolute path to the file, but I don't see the typical notice from EnvInject when it reads in the file as I do when I setup a file for an individual job.  Also the variables I need are not set and my job fails.  I don't see any errors in the console or Jenkins log either.

Am I doing something wrong or is this a known issue?

Thanks

Mark Sinclair

unread,
Feb 17, 2015, 9:27:06 AM2/17/15
to jenkins...@googlegroups.com
I understand the problem now.  The slave envinject requires a slave reboot.  It is working as expected. 

Unfortunately what I want to do is be able to change the contents of the slaves global parameters without rebooting the slave every time.  This does not appear possible.

As a workaround, I will setup each job to pull in the same global parameters file.  This should work for now.

The problem is if any jobs want to include their own properties file.  I read something about an include directive in properties files, but not sure this works with Jenkins.  Anyone tried this?


Reply all
Reply to author
Forward
0 new messages