2012-04-26 3 views

답변

2

bottle.default_app() 가 호출 WSGI 반환

if __name__ == "__main__": 
    bottle_app = bottle.default_app() 
    bottle_handler = tornado.wsgi.WSGIContainer(bottle_app) 
    HTTPServer(Application([(r"/ws", WSHandler), 
          (r"/css/(.*)", StaticFileHandler, {"path": "./css/"}), 
          (r"/js/(.*)", StaticFileHandler, {"path": "./js/"}), 
          (r"/img/(.*)", StaticFileHandler, {"path": "./img/"}), 
          ("/(.*)", bottle_handler)]) 
         ).listen(1024) 
    IOLoop.instance().start() 
+1

내가 이미 프로젝트를 생성을 github에 https://github.com/cime/bottle-tornadosocket :) – redman

관련 문제