| Author |
foobar/work accessible to everybody ?!
|
Mike Riker
Greenhorn
Joined: Mar 28, 2005
Posts: 4
|
|
Hello, not sure is this Tomcat or Eclipse issue, but anyway ... When I create new Tomcat project (sysdeo plugin) with Eclipse, it creates <projectame>/WEB-INF and <projectname>/work directories. Ok, WEB-INF is for sources and classes and work directory is for temp stuff (e.g. jsp's compiled to servlets), right ? When I deploy my application, the work directory is accessible via browser to everybody (?!) Is this a chmod issue, or should the stuff in work directory be placed in WEB-INF or what's going on ? Thanks, - Mike
|
 |
Jeanne Boyarsky
internet detective
Marshal
Joined: May 26, 2003
Posts: 26499
|
|
Mike, Anything you don't want the users to see goes in WEB-INF. I'm moving this to servlets as it isn't IDE specific.
|
[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
|
 |
Ben Souther
Sheriff
Joined: Dec 11, 2004
Posts: 13410
|
|
Is the WEB-INF directory directly under the "work" directory? If so, yes, that's the directory that the browsers can see.
|
Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
|
 |
Mike Riker
Greenhorn
Joined: Mar 28, 2005
Posts: 4
|
|
Originally posted by Ben Souther: Is the WEB-INF directory directly under the "work" directory? If so, yes, that's the directory that the browsers can see.
(Still having a strange feeling that this thread was moved to wrong place) The directory structure that eclipse now creates is: -- someapp/WEB-INF someapp/work -- Is this thing somekind of sysdeo-plugin configuration issue or why on earth it would expose work directory with all the sources by default to everyone... - Mike
|
 |
Ben Souther
Sheriff
Joined: Dec 11, 2004
Posts: 13410
|
|
I'm not sure what Eclipse is doing with the work directory but in a standalone instance of Tomcat (or any other spec compliant container) the 'someApp' directory would be where you put your jsp, html, css, etc... People would also be able to see the "work" directory but they would have to include "someApp/work" in the url. If you have a standalone instance of Tomcat on your machine, you can grab any of the war files from http://simple.souther.us, drop them in your {tomcat_home}/webapps directory, and see what the proper directory structure should be for a servlet app.
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56554
|
|
In the stand-alone version of Tomcat, the work folder is created under $CATALINA_HOME and is not accessible via the browser. Eclipse must be doing something hinky with its internal Tomcat setup. So this is IDE-specific and should be moved back to the forum where Eclipse is discussed. P.S. Other servers such as Resin create the work folder in the web app hiearchy, but it's placed under WEB-INF where it is not browser accessible.
|
[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
|
 |
 |
|
|
subject: foobar/work accessible to everybody ?!
|
|
|