It’s been a long time since I worked on a JSP project and I’m now tasked with the setup of a workspace in Eclipse, this time I’m solely using OS X to develop on. Here are the steps I took to setup my local workspace.
Download the Apache Tomcat
Found under Binary Distribution as a tar.gz under ‘Core’
Move and untar
$ cd /usr/local $ mv ~/Downloads/apache-tomcat-6.0.24.tar . $ tar -xzvf apache-tomcat-6.0.24.tar $ mv apache-tomcat-6.0.24 tomcat6
Starting and Stopping Tomcat
$ mkdir bin $ cd bin
Create a file under called start_tomcat ( e.g. ~/bin/start_tomcat ) with the following contents:
#!/bin/sh export CATALINA_HOME=/usr/local/tomcat6 export JAVA_HOME=/usr $CATALINA_HOME/bin/startup.sh
..and another for stopping tomcat ( e.g. stop_tomcat )
#!/bin/sh export CATALINA_HOME=/usr/local/tomcat6 export JAVA_HOME=/usr $CATALINA_HOME/bin/shutdown.sh
Make the files executable:
$ chmod ug+x start_tomcat stop_tomcat
Now you can start and stop tomcat with commands these commands:
~/bin/start_tomcat ~/bin/stop_tomcat
Apple has some good docs on tomcat, even if they’re out of date.

No Responses (yet)