diff options
author | James Vasile <james@hackervisions.org> | 2011-12-20 21:22:36 -0500 |
---|---|---|
committer | James Vasile <james@jamesvasile.com> | 2012-02-19 15:07:15 -0500 |
commit | 54b8e52a182bea5212f721b1f4ab5d9d2bea0c13 (patch) | |
tree | 40b25ea5b207220bf194989e83e95e574f628627 /plinth.py | |
parent | 77647e907dc8855e85c80449292ca08b7ff5b25a (diff) |
listen locally only, proxy to the outside world
Diffstat (limited to 'plinth.py')
-rwxr-xr-x | plinth.py | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -103,8 +103,8 @@ def setup(): server.subscribe() # Configure default server - cherrypy.config.update({'server.socket_host': '0.0.0.0', - 'server.socket_port': cfg.port, + cherrypy.config.update({'server.socket_host': '127.0.0.1', + 'server.socket_port': cfg.port, 'server.thread_pool':10, 'tools.staticdir.root': cfg.file_root, 'tools.sessions.on':True, @@ -115,15 +115,14 @@ def setup(): }) - config = {'/': {'tools.staticdir.root': '%s/static' % cfg.file_root}, + config = {'/': {'tools.staticdir.root': '%s/static' % cfg.file_root, + 'tools.proxy.on':True,}, '/static': {'tools.staticdir.on': True, 'tools.staticdir.dir':"."}, '/favicon.ico':{'tools.staticfile.on':True, 'tools.staticfile.filename': "%s/static/theme/favicon.ico" % cfg.file_root} } cherrypy.tree.mount(cfg.html_root, '/', config=config) - - cherrypy.engine.signal_handler.subscribe() |