Skip to content

Instantly share code, notes, and snippets.

@mitsuhiko
Created May 14, 2012 11:32
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mitsuhiko/2693484 to your computer and use it in GitHub Desktop.
Save mitsuhiko/2693484 to your computer and use it in GitHub Desktop.
def proxy_fix(application):
def new_application(environ, start_response):
environ['wsgi.url_scheme'] = 'https'
return application(environ, start_response)
return new_application
app.wsgi_app = proxy_fix(app.wsgi_app)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment