Hi Les,

OK, I think I get what you're saying, so this is what I did:

I set ant and java globally in jenkins and pointed java home and ant home
to directories on the jenkins machine (master)

I then added those global settings to my slave node.

I then added a build step to invoke ant, added the global ant setting,
added which target i wanted to run, included the path to the build.xml on
the slave machine.

I ran the job, but it still failed incidcating that it could not find the
specified path to the build.xml..

I'm convinced that Jenkins (master) is not properly delegating my job to
the slave machine...to test this, I had ant execute a simple test batch
file i created to echo "hello world" from the slave, but I got a message
saying that it didn't recognize tha batch file...I then tested this locally
from a command prompt on the jenkins server, where the .bat doesn't exist,
and got the same message.

Again, thanks for the input and advice, but I think the root of my problem
here is  getting the master to properly delagate control to the slave
machine.

Thanks,

-John P.



On Fri, May 2, 2014 at 10:53 AM, Les Mikesell <lesmikes...@gmail.com> wrote:

> On Fri, May 2, 2014 at 9:25 AM, John Park
> <john.p...@sightlinesystems.com> wrote:
> > To be honest, I have never tried invoking ant from the build step in
> > jenkins..I just took a look at it, but I don't see how this would be more
> > beneficial (or easier) for me, since I have everything already set up on
> the
> > slave machine...all I should be doing is executing an ant command to run
> the
> > script.
> >
> > Is there some benefit to invoking ant in jenkins vs executing it from the
> > slave?
>
> I don't think you understand. Invoking ant in jenkins will execute it
> on the slave where the job runs.  But it also lets you set the version
> and location for ant (and the jdk to use) in a high-level way.   That
> is, you can give the versions a name in the global jenkins config, and
> set (potentially different) locations for the tools in each node
> config. And you can pick the versions in your job file (if there are 2
> or more).   Then, even if ant and the jdk(s) are installed in
> different locations on your own workstation, you can tell jenkins to
> run the same ant job from the SCM and it will work regardless of which
> node runs it.
>
> --
>    Les Mikesell
>      lesmikes...@gmail.com
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Jenkins Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/jenkinsci-users/0ELSkd80t_Q/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> jenkinsci-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to