comparison piecrust/wsgiutil/cwdadminapp.py @ 897:b4156f5d4368

wsgi: Add admin panel to WSGI helpers.
author Ludovic Chabant <ludovic@chabant.com>
date Sat, 08 Jul 2017 22:01:00 -0700
parents
children
comparison
equal deleted inserted replaced
896:85d2b386b971 897:b4156f5d4368
1 # This is a utility module that can be used with any WSGI-compatible server
2 # like Werkzeug or Gunicorn. It returns a WSGI app for serving a PieCrust
3 # administration panel located in the current working directory.
4 import os
5 from piecrust.wsgiutil import get_admin_app
6
7
8 root_dir = os.getcwd()
9 app = get_admin_app(root_dir)
10 # Add this for `mod_wsgi`.
11 application = app
12
13