paulb@39 | 1 | #!/usr/bin/env python |
paulb@39 | 2 | |
paulb@39 | 3 | # NOTE: Path manipulation requires manual customisation. |
paulb@39 | 4 | |
paulb@39 | 5 | import sys |
paulb@39 | 6 | sys.path.append("/home/paulb/Software/Python/WebStack") |
paulb@39 | 7 | sys.path.append("/home/paulb/Software/Python/WebStack/examples/Common") |
paulb@39 | 8 | |
paulb@39 | 9 | from WebStack.Adapters import ModPython |
paulb@41 | 10 | from Simple import SimpleResource |
paulb@39 | 11 | |
paulb@39 | 12 | # NOTE: Not sure if the resource should be maintained in a resource pool. |
paulb@39 | 13 | |
paulb@39 | 14 | resource = SimpleResource() |
paulb@39 | 15 | |
paulb@39 | 16 | def handler(req): |
paulb@39 | 17 | global resource |
paulb@341 | 18 | return ModPython.respond(req, resource, handle_errors=0) |
paulb@39 | 19 | |
paulb@39 | 20 | # vim: tabstop=4 expandtab shiftwidth=4 |