I wanted to run a Django app using Python's built-in wsgiref module. It also serves Django admin media. Consider this a stepping stone to running your Django app using CherryPy.
from wsgiref.simple_server import make_serverfrom django.core.handlers.wsgi import WSGIHandlerfrom django.core.servers.basehttp import AdminMediaHandlerhttpd = make_server('', 8000, AdminMediaHandler(WSGIHandler()))httpd.serve_forever()
No comments:
Post a Comment