I have some static files that I would like to serve, and I aware that Django and Python are not suitable for serving static files in a production environment.
My current set up is nginx with python/django behind it wither via nginx_fastcgi or uwsgi workers. Nginx serves up static files like the CSS and the Javascript, and all the dynamic pages are passed on to python to generate.
However there are urls like /user/input/battleships.in
. Here battleships.in
is a static file located on the filesystem at `$MEDIA_ROOT/users/$request.user.username. Is there a way to have django determine the correct url, and then proxy the request back to nginx to serve the static file?