Webmasters Stack Exchange is a question and answer site for pro webmasters. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm currently developing a site hosted on dreamhost, using django, which is served up through passenge wsgi.

Right now, all requests are being passed to the django app. I'd like to be able to serve static content directly through apache, rather than having it go through the app. Is there a way to get passenger to realise that urls with a certain prefix are special, and should just go through to apache?

share|improve this question

It turns out that I don't need to do anything special, but there is a slight twist with the urls: static content in /public/ (e.g. <mydomain>/public/foo/index.html) is served from a url missing the /public, so the example would be served as http://<mydomain>/foo/index.html.

Obviously, trouble will ensue if static directories and django urls clash.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.