[ckan-changes] [ckan/ckan] fdd7cd: Set SERVER_NAME on Flask config

GitHub noreply at github.com
Mon Jun 6 12:14:19 UTC 2016


  Branch: refs/heads/poc-flask-views.common-url_for
  Home:   https://github.com/ckan/ckan
  Commit: fdd7cdbd71eaf9394bbfb1d5da0a3a87507e84e8
      https://github.com/ckan/ckan/commit/fdd7cdbd71eaf9394bbfb1d5da0a3a87507e84e8
  Author: amercader <amercadero at gmail.com>
  Date:   2016-06-06 (Mon, 06 Jun 2016)

  Changed paths:
    M ckan/config/middleware.py
    M ckan/lib/helpers.py

  Log Message:
  -----------
  Set SERVER_NAME on Flask config

This is required for Flask to be able to generate full URLs with
`_external=True` and allows us to get rid of the hack on 15fcae6.

Setting SERVER_NAME made the Flaks app to stop receiving the WSGI
party middleware invitation, thus all requests to Flask returned 404.
After some investigation this was fixed by setting the `HTTP_HOST` key
in the environ sent to the apps during the invite.




More information about the ckan-changes mailing list