Build Parameters in server host names

23 views
Skip to first unread message

David Brossard

unread,
May 22, 2013, 4:59:42 PM5/22/13
to jenkins...@googlegroups.com
I have been trying to setup a single build job that will accept a parameter to build for different environments ie Dev, Prod etc. Obviously I also want these to deploy to different servers.

I can see how to use GIT to check out a different branch using parameters but how then do I send  these parameters in the names of servers to publish over ssh, publish over ftp, publish over cifs etc? We have server names similar to dev.mycompany.com and prod.mycompany.com and I would like to send these to $ENV.mycompany.com.

The problem I have run into is that if I build a different Jenkins jobs for our Dev and Prod servers, occasionally changes to the jobs do not get replicated to every other one.

Kamal Ahmed

unread,
May 22, 2013, 9:53:48 PM5/22/13
to jenkins...@googlegroups.com
David,

But on the jenkins web site (http://jenkins-ci.org/) LTS is:

Java Web Archive (.war)
and the normal (NON LTS )release is:
Java Web Archive (.war)


From: David Brossard <dbro...@gmail.com>
To: jenkins...@googlegroups.com
Sent: Wednesday, May 22, 2013 4:59 PM
Subject: Build Parameters in server host names

I have been trying to setup a single build job that will accept a parameter to build for different environments ie Dev, Prod etc. Obviously I also want these to deploy to different servers.

I can see how to use GIT to check out a different branch using parameters but how then do I send  these parameters in the names of servers to publish over ssh, publish over ftp, publish over cifs etc? We have server names similar to dev.mycompany.com and prod.mycompany.com and I would like to send these to $ENV.mycompany.com.

The problem I have run into is that if I build a different Jenkins jobs for our Dev and Prod servers, occasionally changes to the jobs do not get replicated to every other one.
--
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-use...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 


Eric Pyle

unread,
May 23, 2013, 9:31:17 AM5/23/13
to jenkins...@googlegroups.com
Hi David,

If the concern is keeping multiple jobs in sync, maybe the Template
Project Plugin would help:
https://wiki.jenkins-ci.org/display/JENKINS/Template+Project+Plugin. It
allows you to define one job that holds all the common settings, such as
SCM, build scripts, publishers, etc. and incorporate that into other jobs.

Eric
Reply all
Reply to author
Forward
0 new messages