How is it possible to tune up WebPy to use it to serve static content for several websites?
I run two websites on one IP using web.subdomain_application
for name-based virtual hosting. The implied solution for hosting static content is to create a static/
directory in the directory containing HTTP server script and put all static files from both websited there.
However even if I create sub-directories site1/
and site2/
inside static/
to organize my resources, it would be possible to request Site1's resources on, say, http://site2.com/static/site1/foo.css
. It seems natural to me to restrict such cross-site access to resources.
How to serve static stuff for two sites separately on WebPy?