tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William Barker" <wbar...@wilshire.com>
Subject [PATCH] Exporting Servlet mappings for mod_jk
Date Fri, 02 Mar 2001 00:35:19 GMT
It was getting to be too much work to keep my web.xml files synced with
httpd.conf, so I got ApacheConfig.java to do it for me.  The following is
for Tomcat 3.3M1:
*** ApacheConfig.java.orig      Thu Mar  1 16:40:46 2001
--- ApacheConfig.java   Thu Mar  1 16:38:26 2001
***************
*** 328,337 ****
              mod_jk.println("#");
              mod_jk.println("# The following line mounts all JSP files and
the/servlet/ uri to tomcat");
              mod_jk.println("#");
                    mod_jk.println("JkMount " + path +"/servlet/* " +
JkMount[jkConnector]);
                    mod_jk.println("JkMount " + path +"/*.jsp " +
JkMount[jkConnector]);

-
                    // Deny serving any files from WEB-INF
              mod_jk.println();
              mod_jk.println("#");
--- 328,345 ----
              mod_jk.println("#");
              mod_jk.println("# The following line mounts all JSP files and
the/servlet/ uri to tomcat");
              mod_jk.println("#");
+ /*
                    mod_jk.println("JkMount " + path +"/servlet/* " +
JkMount[jkConnector]);
                    mod_jk.println("JkMount " + path +"/*.jsp " +
JkMount[jkConnector]);
+ */
+            Enumeration ctxMaps = context.getContainerLocations();
+            while(ctxMaps.hasMoreElements()) {
+               String cxpath = (String)ctxMaps.nextElement();
+               if(!cxpath.startsWith("/"))
+                  cxpath = "/"+cxpath;
+               mod_jk.println("JkMount " + path + cxpath +" "+
JkMount[jkConnector]);
+            }

                    // Deny serving any files from WEB-INF
              mod_jk.println();
              mod_jk.println("#");



Mime
View raw message