reverse proxy support

This patch adds reverse-proxy support. See http://flask.pocoo.org/snippets/35/ or `leselys/core.py` for nginx setup instructions.