Raible's Wiki
Raible Designs AppFuseHomepage- Korean - Chinese - Italian - Japanese QuickStart Guide User Guide Tutorials Other ApplicationsStruts ResumeSecurity Example Struts Menu
Set your name in
UserPreferences
Referenced by
JSPWiki v2.2.33
Hide Menu |
This is version 13.
It is not the current version, and thus it cannot be edited. It's pretty easy to setup your AppFuse application to work with CruiseControl. You can either download the files from this page or if you're using 1.6.1+ - they're located in the extras/cruisecontrol directory. Thanks to Mike Clark and Jared Richardson for their help getting this work. NOTE: The main lesson I learned when trying to get this to work is don't use Cygwin. In fact, I recommend you use a *nix machine if you have one available
To run CruiseControl on your AppFuse project, perform the following steps: 1. Download and install CruiseControl. Extract it to your $TOOLS_HOME directory, wherever that may be. 2. After you've installed CruiseControl, create an "appfuse-cc" or similar directory next to your project directory. In my tests, I had: c:\Source c:\Source\appfuse c:\Source\appfuse-cc 3. Download the following files and put them in the "appfuse-cc" directory: The latest version of these files can be found in CVS or in your project's extras/cruisecontrol directory. 4. Modify cruise.sh to point to the installed directory. If you're on Windows, rename cruise.sh to cruise.bat and point to the cruisecontrol.bat file. 5. Modify config.xml for your Ant path and publishing directories. 6. Modify build.xml so it points to your CVS server and project. 7. Run "ant" in the current directory or checkout your project into the "checkout" directory (you'll need to create it). You can also run this on the "appfuse" project for testing purposes. 8. Create a "logs/appfuse" directory in the current directory. 9. Run "cruise.sh". 10. Tweak the publishers in config.xml to your heart's content. I was puzzled why my HTML E-Mails didn't contain all the pretty formatting like Spring's does. Then I looked at their latest archived one and noticed it looks the same on Gmane as it does in GMail. I'd recommend sending your build notifications to an e-mail account that can be read with a good HTML e-mail reader. If you want to use CruiseControl to build your Equinox project, that's in Equinox's CVS. Setup CruiseControl DaemonAfter getting all the above working, I setup CruiseControl to run as a daemon. I has some issues with getting these instructions working, so I pinged the mailing list. After a few back-and-forth e-mails, the following solution worked for me on Suse 9.0.
#!/bin/sh # # Edit these variables to suit your Cruise Control installation # chkconfig: - 345 99 05 # description: Script used to start and stop the CruiseControl auto-build system # CCDIR=/home/cc/cruisecontrol CCSTARTSCRIPT=${CCDIR}/main/bin/cruisecontrol.sh CCCONFIGFILE=/home/cc/work/config.xml CCLOGFILE=/home/cc/cc-daemon.log CCPORT=8000 CCCOMMAND="${CCSTARTSCRIPT} -configfile ${CCCONFIGFILE} -port ${CCPORT}" CCUSER=cc # # DO NOT CHANGE ANTHING BELOW THIS LINE # umask 002 export CCDIR # PPID is read-only PARPID=`ps -ea -o "pid ppid args" | grep -v grep | grep "${CCSTARTSCRIPT}" | sed -e 's/^ *//' -e 's/ .*//'` if [ "${PARPID}" != "" ] then PID=`ps -ea -o "pid ppid args" | grep -v grep | grep java | grep "${PARPID}" | \ sed -e 's/^ *//' -e 's/ .*//'` fi case "$1" in 'start') su - ${CCUSER} -c "${CCCOMMAND}" > ${CCLOGFILE} 2>&1 & RETVAL=$? echo "cruisecontrol started with jmx on port ${CCPORT}" ;; 'stop') if [ "${PID}" != "" ] then kill -9 ${PID} ${PARPID} $0 status RETVAL=$? else echo "cruisecontrol is not running" RETVAL=1 fi ;; 'status') kill -0 ${PID} >/dev/null 2>&1 if [ "$?" = "0" ] then echo "cruisecontrol (pid ${PARPID} ${PID}) is running" RETVAL=0 else echo "cruisecontrol is stopped" RETVAL=1 fi ;; 'restart') $0 stop && $0 start RETVAL=$? ;; *) echo "Usage: $0 { start | stop | status | restart }" exit 1 ;; esac exit ${RETVAL}
cd /etc/rc.d/rc5.d ln -s /etc/init.d/cruisecontrol S18cruisecontrol That's it - you should be able to run /etc/init.d/cruisecontrol as root and CC will check for new updates every hour. Attachments:
|