Mercurial > hg > index.fcgi > www > www-1
diff index_test_server.py @ 48:50de1845520f
add first draft of index_app.py
author | paulo |
---|---|
date | Tue, 12 Mar 2013 01:43:17 -0700 |
parents | |
children | 0fbe37b56e84 |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/index_test_server.py Tue Mar 12 01:43:17 2013 -0700 1.3 @@ -0,0 +1,14 @@ 1.4 +import wsgiref.simple_server 1.5 +import SocketServer 1.6 + 1.7 +import index_app 1.8 + 1.9 + 1.10 +class ThreadingWSGIServer(SocketServer.ThreadingMixIn, wsgiref.simple_server.WSGIServer): 1.11 + pass 1.12 + 1.13 + 1.14 +if __name__ == "__main__": 1.15 + httpd = ThreadingWSGIServer(('', 8000), wsgiref.simple_server.WSGIRequestHandler) 1.16 + httpd.set_app(index_app.app) 1.17 + httpd.serve_forever()