Checkout will put the files on agent, I need it on master node Jenkins

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Checkout will put the files on agent, I need it on master node Jenkins

SARDARNI NK
Hi Everyone,

 The checkout will put the files on the agent, I need it on the master node.

Could anyone can help me.

Is there anyway to setup another Jenkins job that can copy the code on the master?

Currently, I am copy file.sh in manually on the master, and calling that file in Jenkins job using 

In job, I am using execute groovy system script plugin and passing the Master node local path  /home/file.sh

def sout = new StringBuilder(), serr = new StringBuilder()

def proc = '/home/file.sh'.execute()

proc.consumeProcessOutput(sout, serr)

I am not sure if in executed groovy system script we can so pass svn path location.


Thanks,
Nav



--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/d1dd39b2-4851-4784-a18b-3a6f0fe50e77%40googlegroups.com.
Reply | Threaded
Open this post in threaded view
|

Re: Checkout will put the files on agent, I need it on master node Jenkins

Jan Monterrubio
You can run jobs on master, there’s a “specify where to run” option and if you put master on there the checkout And any scripts should be on master. 

On Mon, May 11, 2020 at 17:44 SARDARNI NK <[hidden email]> wrote:
Hi Everyone,

 The checkout will put the files on the agent, I need it on the master node.

Could anyone can help me.

Is there anyway to setup another Jenkins job that can copy the code on the master?

Currently, I am copy file.sh in manually on the master, and calling that file in Jenkins job using 

In job, I am using execute groovy system script plugin and passing the Master node local path  /home/file.sh

def sout = new StringBuilder(), serr = new StringBuilder()

def proc = '/home/file.sh'.execute()

proc.consumeProcessOutput(sout, serr)

I am not sure if in executed groovy system script we can so pass svn path location.


Thanks,
Nav



--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/d1dd39b2-4851-4784-a18b-3a6f0fe50e77%40googlegroups.com.

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9Kp%2Bs--RmFUhx%2BCSs80P5YfQLqM8M_iz_x3Y%2B38yqEu_Q%40mail.gmail.com.
Reply | Threaded
Open this post in threaded view
|

Re: Checkout will put the files on agent, I need it on master node Jenkins

SARDARNI NK
Thank you.
Master node executors 0 and we don't to provide executors to any numbers for good practices.

I am not using any labels on the job too.

Thanks,
Nav

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/8c9564f6-62a2-4fde-8b62-c97b107bdb33%40googlegroups.com.
Reply | Threaded
Open this post in threaded view
|

Re: Checkout will put the files on agent, I need it on master node Jenkins

Mark Waite-2
You might consider treating the file that you want to store on the master as an artifact.  The artifact is then available from the master even if the agent workspace is deleted.  That doesn't place it at an exact location, but does retain it even after a workspace is removed.

On Mon, May 11, 2020 at 7:10 PM SARDARNI NK <[hidden email]> wrote:
Thank you.
Master node executors 0 and we don't to provide executors to any numbers for good practices.

I am not using any labels on the job too.

Thanks,
Nav

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/8c9564f6-62a2-4fde-8b62-c97b107bdb33%40googlegroups.com.

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtG33CXaqe_-hj-xKM02Bs11Xo4zE1tQ%2BPe%2BgXGofAcWbw%40mail.gmail.com.
Reply | Threaded
Open this post in threaded view
|

Re: Checkout will put the files on agent, I need it on master node Jenkins

SARDARNI NK
Thank you Mark let me try this approach.

Thanks,
Nav

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/f86bbcb6-f9c6-4b92-9bff-8a2d1d429f4c%40googlegroups.com.