August'24: Kamaelia is in maintenance mode and will recieve periodic updates, about twice a year,
primarily targeted around Python 3 and ecosystem compatibility.
PRs are always welcome. Latest Release: 1.14.32 (2024/3/24)
How do I get
Django working with Kamaelia Publish?
It is possible to get Django working with Kamaelia Publish, however
Django support is highly experimental (as is Django's WSGI support).
Kamaelia Publish includes a built in application for serving Django
applications located at plugins.WsgiApps.django_app. This app
(probably) requires two variables to be set in the urls file:
project_path and django_path_handling.
- project_path is essentially the directory that contains your django
project
- django_path_handling is just a boolean value. What you set it to
isn't really important (I just use "True"), just as long as it is set to
something other than an empty string. This setting exists because
django's path handling isn't very WSGI-centric. It will essentially
prepend the WSGI SCRIPT_NAME environment variable to the beginning of
the WSGI PATH_INFO variable and store the result in PATH_INFO.
Please
note that django support is still experimental (more so than integration
with other frameworks) and as such probably won't work right for your
purposes.