Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

CGI and Tomcat

 
Kevin Wright
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a Tomcat web server, and since my application is fairly small, I would like to serve web pages from it as opposed to the Apache HTTP server. The only problem is, I need to run CGIs - is there a way to do this in Tomcat?
Thanks,
Kevin
 
Thomas Paul
mister krabs
Ranch Hand
Posts: 13974
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did some quick reserach on the mailing lists and it appears the answer is no.
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I did a slightly less quick search.

The answer is a tentative yes, seeing as how I've never done it myself... but look in the CATALINA_HOME\conf\web.xml file, around line 190 you'll see a huge block commented out:
<!-- Common Gateway Includes (CGI) processing servlet, which supports -->
<!-- execution of external applications that conform to the CGI spec -->
<!-- requirements. Typically, this servlet is mapped to the URL pattern -->
<!-- "/cgi-bin/*", which means that any CGI applications that are -->
<!-- executed must be present within the web application. This servlet -->
<!-- supports the following initialization parameters (default values -->
<!-- are in square brackets): -->
I also searched through my few-month archive on the Tomcat-Users list, but hadn't found any references to this ability. So it's probably untried and not popular. After all, JSP/Servlets are supposed to replace all that Perl/C/C++ cgi stuff, right?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic