Installing Tomcat on a MacBook

Today I installed Tomcat on my MacBook. In order to run a website with Java servlets locally.

Here are my non-developer notes, for my own future reference.

To check if Java is installed, open Terminal and type:
javac -version

In a previous session, I had already installed the Apple developer tools, which includes JDK 1.5.

Note: you’ll need to list the location where Java can be found:
export JAVA_HOME=/usr

Download and unpack the Tomcat zip files to a directory.
Open conf/tomcat-users.xml and change the user and password settings.

Go to your Tomcat directory and type ./bin/startup.sh

Open a browser and type http://localhost:8080 to see a Tomcat welcome screen.

In the final step, I modified conf/server.xml. Luckily I had my Windows setup to refer back to, or I would have been really lost at this stage…

tomcat

Author: nchenga

Nchenga-nchenga is my nickname. Chiperoni.ch is my online playground, scrap book, and on-going collection of bookmarks and interesting quotes. Chiperoni is a Malawian term for cold, grey, rainy weather. I am a bridge blogger somewhere between Basel and Blantyre. The opinions and comments expressed here are my own personal opinions and do not represent my employer's view in anyway. So far, this blog is free of advertising or paid articles or similar.

Comments

  1. that sounds, just to easy. What OS are you running.
    After learning HTMl, CSS PHP MySQL i saw a need for Ajax and the author is referencing Tomcat for a development environment. Book: Web Development with javascript and Ajax illuminated, jones and bartlett.

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.