Tue, 28 Jan 2003

Cocoon Portal For Imbeciles

If you're new to Cocoon, you'll find a comprehensive description here. I've been using Cocoon off and on since 1999 and have all of the appropriate battle scars from trying to get it running back in it's early days. Suffice it to say that the install and config for cocoon have come along way since the 1.x release. I've been researching portal technology for a project at work and came across Matthew Langham and Carsten Ziegler's article about the Cocoon Portal technology.

I decided to dive in and give it a try and I'm happy to report that using Java, Jetty, Cocoon, and the Cocoon Portal technology, I was able to get it running in about an hour. If you'd like to give it a try, follow the instructions below. I did this experiment on Redhat Linux 8. If you're on another platform YMMV. Of course, this assumes that you're an imbecile that knows how to do sysadmin on your target platform and has some level of comfort with Java. ;->

  1. Download and install the latest JDK for your platform
  2. Download and install the latest version of Jetty
    Installation shoul consist of expanding the zip and setting JETTY_HOME and JAVA_HOME appropriately. Test installation by issuing /usr/java/j2sdk1.4.1_01/bin/java -jar start.jar and load http://localhost:8080/ in your browser. You should see something like this.
  3. Put this file in JETTY_HOME/etc.
  4. Download the latest version of Cocoon
    I chose cocoon-2.0.4-vm14-bin.tar.gz. Unzip into the default directory. Create a cocoon directory in JETTY_HOME/webapps and copy cocoon.war from the root of the cocoon distribution to the newly created cocoon directory. Issue the following command in the newly created cocoon directory: jar xvf cocoon.war This will expand the cocoon web archive so that jetty can parse it. The cocoon portal technology can be found in the root of the expanded cocoon.war under a directory titled sunspotdemo
  5. Issue the following command to start cocoon: /usr/java/j2sdk1.4.1_01/bin/java -jar start.jar etc/cocoon.xml Wait for a message resembling the following: 18:34:14.660 EVENT Started org.mortbay.jetty.Server@1d8957f Open http://localhost:8080/cocoon/ in your browser. You should see something like this.
  6. Access the portal by typing http://localhost:8080/cocoon/sunspotdemo-portal in your browser. You should see something like this.
That's it! You're now running the cocoon portal technology successfully. Phew!

Posted at: 18:06 | permalink