-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Jean-Pierre,
On 2/21/12 11:04 AM, Jean-Pierre Bergamin wrote: > I'm trying to configure tomcat 7 on Windows to serve static files. > During development I want to have uncompresses javascript files > delivered directly from the file system. Serve uncompressed javascript files? That should be easy. (Why bother to say "uncompressed". Presumably they are also unencrypted, and un-obfuscated and a whole bunch of other things that they are not.) > I followed this blog post > http://th1rty7.blogspot.com/2009/05/tomcat-is-often-considered-to-be-too.html > > and > configured a context in the server.xml file like: Bad premise (Tomcat is just fine when serving static content), bad advice (configuring a <Context> in server.xml) and bad writing (<Context> is an element, not a parameter). > <Host name="localhost" appBase="webapps" unpackWARs="false" > autoDeploy="false" deployOnStartup="false" createDirs="false"> > <Valve className="org.apache.catalina.valves.AccessLogValve" > directory="serviceability/logs/access" > prefix="localhost_access_log." suffix=".txt" pattern="common" > resolveHosts="false"/> Why do you have deployOnStartup="false"? > <Valve > className="org.eclipse.virgo.web.tomcat.support.ApplicationNameTrackingValve"/> > > <Context docBase="D:/Downloads/dojo-release-1.7.1-src" > path="/dojo/1.7.1" /> Take the <Context> out of your server.xml and put it here: CATALINA_BASE/conf/Catalina/localhost/dojo.xml: <Context docBase="D:/Downloads/dojo-release-1.7.1-src" /> > When I try to load a file i.e. with > http://localhost:8080/dojo/1.7.1/dojo/dojo.js I get a 404. Okay. Where is the dojo.js file on the filesystem? - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk9D0r4ACgkQ9CaO5/Lv0PAHvQCdFVi4691RugJo7DhOyoyYuYLH dYUAniOngqy/JLOoqTb1U6XKhfYrG6gA =+U4I -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org