Discussion:
Can you specify a host / agent for a single build step in a freestyle project?
Adam von Nieda
2018-12-06 22:06:36 UTC
Permalink
Hi folks,

I’m able to split parts of a build across multiple nodes using a pipeline, is there any way to do that with a freestyle project? Maybe a plugin I haven’t run across?

For example, my project might look like the following..

Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2

I have steps that have to run on specific nodes.

Thanks for any insight you might have!

-Adam vonNieda
--
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+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/A6478625-CB00-49F8-9602-DE745B034D3E%40vonnieda.org.
For more options, visit https://groups.google.com/d/optout.
Jan Monterrubio
2018-12-06 23:22:30 UTC
Permalink
I think a declarative pipeline might be able to accomplish this with the
“agent” closure.

Iirc the free style project will run all in a single node.
Post by Adam von Nieda
Hi folks,
I’m able to split parts of a build across multiple nodes using a
pipeline, is there any way to do that with a freestyle project? Maybe a
plugin I haven’t run across?
For example, my project might look like the following..
Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2
I have steps that have to run on specific nodes.
Thanks for any insight you might have!
-Adam vonNieda
--
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
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/A6478625-CB00-49F8-9602-DE745B034D3E%40vonnieda.org
.
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+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9JvTROpgoCrK6SMr%2BBFfuLCZb%3D_4WfxoyaT3NwMTbzi6Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Adam von Nieda
2018-12-06 23:52:04 UTC
Permalink
Thanks very much for the reply Jan, I’m aware of being able to do this with a pipeline. I’ll ask again in case anyone else wants to respond. By the way, a freestyle project is not necessarily isolated to a single node, you can specify labels or individual servers using the NodeLabel plugin. That’s different from what I’m asking below though.


I’m able to split parts of a build across multiple nodes using a pipeline, is there any way to do that with a freestyle project? Maybe a plugin I haven’t run across?

For example, my project might look like the following..

Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2

I have steps that have to run on specific nodes.

Thanks for any insight you might have!

--
Adam vonNieda
I think a declarative pipeline might be able to accomplish this with the “agent” closure.
Iirc the free style project will run all in a single node.
Hi folks,
I’m able to split parts of a build across multiple nodes using a pipeline, is there any way to do that with a freestyle project? Maybe a plugin I haven’t run across?
For example, my project might look like the following..
Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2
I have steps that have to run on specific nodes.
Thanks for any insight you might have!
-Adam vonNieda
--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/A6478625-CB00-49F8-9602-DE745B034D3E%40vonnieda.org <https://groups.google.com/d/msgid/jenkinsci-users/A6478625-CB00-49F8-9602-DE745B034D3E%40vonnieda.org>.
For more options, visit https://groups.google.com/d/optout <https://groups.google.com/d/optout>.
--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9JvTROpgoCrK6SMr%2BBFfuLCZb%3D_4WfxoyaT3NwMTbzi6Q%40mail.gmail.com <https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9JvTROpgoCrK6SMr%2BBFfuLCZb%3D_4WfxoyaT3NwMTbzi6Q%40mail.gmail.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout <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+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/9FA3D883-1C4C-410E-B971-357859C44F09%40vonnieda.org.
For more options, visit https://groups.google.com/d/optout.
Eric Pyle
2018-12-07 14:12:35 UTC
Permalink
This isn't exactly what you asked, but you could:
1. Break up each step into its own freestyle job, and give each of those
sub-jobs a parameter of type Node or Label.
2. In the main job, call each sub-job using the build step "Trigger/call
builds on other projects", passing the desired agent as a parameter. You
could also pass "Current build parameters" or environment variables to
give the build step what it needs.

-Eric
  Thanks very much for the reply Jan, I’m aware of being able to do
this with a pipeline. I’ll ask again in case anyone else wants to
respond. By the way, a freestyle project is not necessarily isolated
to a single node, you can specify labels or individual servers using
the NodeLabel plugin. That’s different from what I’m asking below though.
I’m able to split parts of a build across multiple nodes using a
pipeline, is there any way to do that with a freestyle project? Maybe
a plugin I haven’t run across?
For example, my project might look like the following..
Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2
  I have steps that have to run on specific nodes.
  Thanks for any insight you might have!
--
Adam vonNieda
Post by Jan Monterrubio
I think a declarative pipeline might be able to accomplish this with
the “agent” closure.
Iirc the free style project will run all in a single node.
   Hi folks,
   I’m able to split parts of a build across multiple nodes using
a pipeline, is there any way to do that with a freestyle project?
Maybe a plugin I haven’t run across?
For example, my project might look like the following..
Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2
   I have steps that have to run on specific nodes.
   Thanks for any insight you might have!
   -Adam vonNieda
--
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,
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/A6478625-CB00-49F8-9602-DE745B034D3E%40vonnieda.org.
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,
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9JvTROpgoCrK6SMr%2BBFfuLCZb%3D_4WfxoyaT3NwMTbzi6Q%40mail.gmail.com
<https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9JvTROpgoCrK6SMr%2BBFfuLCZb%3D_4WfxoyaT3NwMTbzi6Q%40mail.gmail.com?utm_medium=email&utm_source=footer>.
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
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/9FA3D883-1C4C-410E-B971-357859C44F09%40vonnieda.org
<https://groups.google.com/d/msgid/jenkinsci-users/9FA3D883-1C4C-410E-B971-357859C44F09%40vonnieda.org?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.
--
Eric Pyle
Siemens PLM Software
Lebanon, NH
+1 603-277-3060
***@siemens.com
http://www.siemens.com/plm
--
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+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/50722a2d-f907-afa0-05cd-43d34ccc9e3e%40siemens.com.
For more options, visit https://groups.google.com/d/optout.
Adam von Nieda
2018-12-07 14:27:17 UTC
Permalink
Thanks for the reply Eric, yeah that’s a workaround I could try. I was hoping there was some plugin that I hadn’t been able to find that made it simple, but I guess not.

Best regards,

-Adam

--
Adam vonNieda
1. Break up each step into its own freestyle job, and give each of those sub-jobs a parameter of type Node or Label.
2. In the main job, call each sub-job using the build step "Trigger/call builds on other projects", passing the desired agent as a parameter. You could also pass "Current build parameters" or environment variables to give the build step what it needs.
-Eric
Post by Adam von Nieda
Thanks very much for the reply Jan, I’m aware of being able to do this with a pipeline. I’ll ask again in case anyone else wants to respond. By the way, a freestyle project is not necessarily isolated to a single node, you can specify labels or individual servers using the NodeLabel plugin. That’s different from what I’m asking below though.
I’m able to split parts of a build across multiple nodes using a pipeline, is there any way to do that with a freestyle project? Maybe a plugin I haven’t run across?
For example, my project might look like the following..
Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2
I have steps that have to run on specific nodes.
Thanks for any insight you might have!
--
Adam vonNieda
I think a declarative pipeline might be able to accomplish this with the “agent” closure.
Iirc the free style project will run all in a single node.
Hi folks,
I’m able to split parts of a build across multiple nodes using a pipeline, is there any way to do that with a freestyle project? Maybe a plugin I haven’t run across?
For example, my project might look like the following..
Step1: Execute on node 2
Step 2: Execute on node 3
Step 3: Execute on node 1
Step 4: Execute on node 2
I have steps that have to run on specific nodes.
Thanks for any insight you might have!
-Adam vonNieda
--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/A6478625-CB00-49F8-9602-DE745B034D3E%40vonnieda.org <https://groups.google.com/d/msgid/jenkinsci-users/A6478625-CB00-49F8-9602-DE745B034D3E%40vonnieda.org>.
For more options, visit https://groups.google.com/d/optout <https://groups.google.com/d/optout>.
--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9JvTROpgoCrK6SMr%2BBFfuLCZb%3D_4WfxoyaT3NwMTbzi6Q%40mail.gmail.com <https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9JvTROpgoCrK6SMr%2BBFfuLCZb%3D_4WfxoyaT3NwMTbzi6Q%40mail.gmail.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout <https://groups.google.com/d/optout>.
--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/9FA3D883-1C4C-410E-B971-357859C44F09%40vonnieda.org <https://groups.google.com/d/msgid/jenkinsci-users/9FA3D883-1C4C-410E-B971-357859C44F09%40vonnieda.org?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout <https://groups.google.com/d/optout>.
--
Eric Pyle
Siemens PLM Software
Lebanon, NH
+1 603-277-3060
http://www.siemens.com/plm <http://www.siemens.com/plm>
--
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+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/F1AB2E63-5B06-4C8F-9B0A-47C3A02DC0DA%40vonnieda.org.
For more options, visit https://groups.google.com/d/optout.
Loading...