Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I just find out that it is possible to create public webserver through "preference". Is it possible to make this "webserver" to a Apache Tomcat server? I develop in Java/Jsp/Servlet..

I use Lion and I'm new to Mac

share|improve this question

migrated from Oct 23 '11 at 17:26

This question came from our site for professional and enthusiast programmers.

No. The System Preferences setting only activates Apache HTTP Server.

You can set up Tomcat stand-alone yourself, or configure Apache to use mod_jk to connect to Tomcat as described e.g. here.

share|improve this answer

Yes of course. But the firewall doesn't make it simple nowadays. In earlier versions of OSX you could add a port exception to the firewall, which isn't possible AFAICS. You can install the Waterroof firewall frontend.

Another option is to use apache as frontend to tomcat, using Mod_JK.

A third option, if you don't need Apache, is to make Tomcat listen to port 80, and disable Apache. Enabling the webserver in the firewall does make OSX start the webserver. So you probably should make Apache use another port as well, say port 9090. Then apache starts, when the firewall starts it, and you start tomcat manually.


Open server.xml

<Connector connectionTimeout="20000" port="8080"

Should be: port="80"



Edit httpd.conf

listen 80

should be: listen 9090


share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.