0

I need to create a Build Server in CentOS 6.4 Minimal I sucessfully installed:

  • Java compiler (OpenJDK 1.7.0)
  • Git or Mercurial
  • Maven
  • Jenkins

Now I need to to the following:

At given intervals (eg daily at midnight) is the latest revision in the version control system (tip, HEAD, ...) compiled with Maven. In addition, Java Docs and packages (jar, war) need to be created.

Then Jenkins with all tests conducted and reported.

  • Make sure there is a report of previous builds
  • Ensure that the Java Docs and packages can be downloaded (jars, wars, ...) of the latest build

I can't use a GUI on CentOS Minimal so I need to configure the job in xml files? Could please someone show me the way... I'm not a linux server guru.

8bitboy
  • 63
  • 3
  • 11

1 Answers1

0

It's a bit impractical to configure Jenkins via XML by hand, because Jenkins' configuration is spread over multiple files, and the format of the configuration files changes between releases.

Given that Jenkins is a web application, you should be able to visit port 8080 (Jenkins' default port, assuming you didn't change it) on the server where you installed Jenkins (e.g. http://mycentosserver.example.com:8080), and configure it via the web interface.

If you're unable to access the web interface because of a firewall or similar, but you are able to SSH to the server (presumably you can, given that you were able to install stuff on it), you could set up an SSH tunnel to forward a port on your local machine to port 8080 on the server. For example, from your local machine, run the following command. You will then be able to access Jenkins on your local machine at http://localhost:28080 . If you're on Windows, you can use Putty to do the same thing.

ssh -L 28080:127.0.0.1:8080 mycentosserver.example.com

If you can't access the web app directly, and you can't SSH tunnel, I'd recommend setting up Jenkins on a server where you can access the web app, configuring it, and copying the XML config files from /var/lib/jenkins on that server across to your Centos server.

Daniel
  • 10,115
  • 3
  • 44
  • 62
  • I have used ssh, X11 forwarding and Xming to safely use the server :) I can now run firefox on my local machine. – 8bitboy Aug 15 '13 at 15:07
  • Which project should I choose if I create a new Job? I think Maven2/3 project looks suitable? – 8bitboy Aug 15 '13 at 15:11
  • Which plugins will I need to generate reports of previous builds and test results? – 8bitboy Aug 15 '13 at 16:43