0

I have created a Jenkins job which used to run in the master and I have the build.xml file in the master.

Now I have added a slave node and added the setting Restrict where this project can be run so that my job always runs on a particular slave.

Now my build jobs are failing and I can see:

[EnvInject] - Loading node environment variables.
Building remotely on demo_slave_inst2 (slave1) in workspace /root/slave/workspace/demo_job
FATAL: Unable to find build script at /root/slave/workspace/demo_job/autobvt.xml
Build step 'Invoke Ant' marked build as failure
Recording test results
Finished: FAILURE

This autobvt.xml file already exists in the master. So looks like I need to copy this file over to the slave node manually which does not looks like quite handy.

How I can instruct jenkins to copy this as part of the build?

Exploring
  • 2,493
  • 11
  • 56
  • 97

2 Answers2

1

Use "Copy data to Workspace" http://wiki.jenkins-ci.org/display/JENKINS/Copy+Data+To+Workspace+Plugin using which you can copy the files from master to slave and run them as a part of build process (No manual effort needed!)

Waman
  • 1,179
  • 7
  • 16
0

I sorted the issue using the Copy to Slave plugin.

Exploring
  • 2,493
  • 11
  • 56
  • 97