Reputation: 9465
I have a Tomcat 6.0.24 server running. I'm using to run some JSP pages. Would it be possible to host files on it? E.g. If I type in http://localhost:8080/Sample.avi I would download Sample.avi? Probably there are better servers I guess for this task, but I'd like to stick to Tomcat since I don't wish to install another server. Is it possible?
Thanks and regards, Krt_Malta
Upvotes: 3
Views: 5993
Reputation: 113
If you are using IntelliJ,
Upvotes: 0
Reputation: 180020
Yes, it's possible. A quick google suggests you need a StaticInterceptor
What you call "files" is usually called "static content" in web terms: a fixed resource at a specific URI.
Upvotes: 1
Reputation: 32841
It's possible: simply add a <Context> in the server.xml file to point to the directory containing you files.
Upvotes: 3