web.web.httpserver

Package web :: Package web :: Module httpserver |
[hide private]
[frames] | no frames]

# Module httpserver

source code

Classes | [hide private]
| StaticApp WSGI application for serving static files.
| StaticMiddleware WSGI middleware for serving static files.
| LogMiddleware WSGI middleware for logging the status.

Functions | [hide private]
runbasic(func, server_address=`(``'``0.0.0.0``'``,` 8080`)`) Runs a simple HTTP server hosting WSGI app `func`. | source code
runsimple(func, server_address=`(``'``0.0.0.0``'``,` 8080`)`) Runs [CherryPy][cp] WSGI server hosting WSGI app `func`. | source code
WSGIServer(server_address, wsgi_app) Creates CherryPy WSGI server listening at `server_address` to serve `wsgi_app`. | source code

Variables | [hide private]
| __package__ = ``'``web.web``'``

Function Details | [hide private]

### runbasic(func, server_address=`(``'``0.0.0.0``'``,` 8080`)`) | source code
      Runs a simple HTTP server hosting WSGI app `func`. The directory `static/`
      is hosted statically.

      Based on [WsgiServer][ws] from [Colin Stewart][cs].

    [ws]: http://www.owlfish.com/software/wsgiutils/documentation/wsgi-server-api.html
    [cs]: http://www.owlfish.com/

### runsimple(func, server_address=`(``'``0.0.0.0``'``,` 8080`)`) | source code
Runs [CherryPy][cp] WSGI server hosting WSGI app `func`. The directory `static/` is hosted statically. [cp]: http://www.cherrypy.org

### WSGIServer(server_address, wsgi_app) | source code
Creates CherryPy WSGI server listening at `server_address` to serve `wsgi_app`. This function can be overwritten to customize the webserver or use a different webserver.