|
|
| (8 intermediate revisions by the same user not shown) |
| Line 1: |
Line 1: |
| [[Category:Continuous Integration]] | | #Redirect [[Jenkins]] |
| | |
| Hudson is a continuous integration tool built using Java. It can work as a standalone server since it has the Winstone Servlet Container or it can work on various Servlet Containers or JEE servers such as [[Apache Tomcat]], Glassfish, JBoss, IBM WebSphere, Jetty 6, etc. Hudson supports Apache Ant and [[Maven]] as well as SCM tools such as CSV and [[Subversion]].
| |
| | |
| == Installation ==
| |
| * Download the latest hudson from the [https://hudson.dev.java.net/ hudson web site].
| |
| * Deploy <code>hudson.war</code> file as a web application to Tomcat server.
| |
| | |
| == Use Subdomain to Access Hudson (with SSL) ==
| |
| * Install and enable [http://lckymn.com/wiki/Apache_Tomcat#Using_mod_jk mod_jk].
| |
| * Open the <code>workers.properties</code> file in the <code>/etc/apache2</code> directory.
| |
| * Add a new <code>worker</code> for hudson.
| |
| workers.tomcat_home=/opt/tomcat
| |
| workers.java_home=/usr/lib/jvm/java-6-sun
| |
| ps=/
| |
| worker.list=worker1,'''hudson'''
| |
| worker.worker1.port=8009
| |
| worker.worker1.host=localhost
| |
| worker.worker1.type=ajp13
| |
| worker.worker1.lbfactor=1
| |
| '''worker.hudson.port=8009'''
| |
| '''worker.hudson.host=hudson.yourdomain.com'''
| |
| '''worker.hudson.type=ajp13'''
| |
| '''worker.hudson.lbfactor=1'''
| |
| | |
| * Set up <code>JkMount</code> in the apache virtual host configuration.
| |
| <VirtualHost *:443>
| |
| ServerAdmin master@yourdomain.com
| |
|
| |
| SSLEngine on
| |
|
| |
| SSLOptions +StrictRequire
| |
|
| |
| SSLCertificateFile /etc/ssl/certs/server.crt
| |
| SSLCertificateKeyFile /etc/ssl/private/server.key
| |
|
| |
| ServerName hudson.yourdomain.com
| |
|
| |
| JkMount / hudson
| |
| JkMount /* hudson
| |
|
| |
| </VirtualHost>
| |
| | |
| * Open the <code>$CATALINA_HOME/conf/server.xml</code> file to set up a new tomcat virtual host for the hudson.
| |
| * Add the virtual host info inside the <code>Engine</code> element.
| |
| <source lang="xml">
| |
| <Engine name="Catalina" defaultHost="localhost">
| |
| ... Default Host Info ...
| |
| | |
| <Host name="hudson.yourdomain.com" appBase="webapps"
| |
| unpackWARs="true" autoDeploy="true"
| |
| xmlValidation="false" xmlNamespaceAware="false">
| |
| <Context path="" docBase="hudson" debug="0" reloadable="true" />
| |
| </Host>
| |
| </Engine>
| |
| </source>
| |
| * The docBase, '<code>hudson</code>', must exist in the <code>$CATALINA_HOME/webapps<code> directory. (It should be there after normal deployment through Tomcat).
| |
| $CATALINA_HOME/webapps/application_path
| |
| | |
| * Restart tomcat and apche.
| |
| $ /etc/init.d/tomcat stop
| |
| $ /etc/init.d/tomcat start
| |
| $ /etc/init.d/apache restart
| |
| | |
| * access <code>https://hudson.yourdomain.com</code>
| |