Guest User

Untitled

a guest
Jan 21st, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. import tornado.web
  2. import tornado.httpserver
  3. import tornado.ioloop
  4.  
  5. class DefaultHandler(tornado.web.RequestHandler):
  6. def get(self):
  7. self.write("Nothing to see here\n")
  8.  
  9. if __name__ == "__main__":
  10. app = tornado.web.Application([
  11. (r"/", DefaultHandler),
  12. # (r"/RPC2", MainHandler, dict(core=core))
  13. ])
  14. ssl_options = {'certfile': '/home/kamil/code/bcfg2-repo/bcfg2.crt',
  15. 'keyfile': '/home/kamil/code/bcfg2-repo/bcfg2.key',
  16. }
  17. server = tornado.httpserver.HTTPServer(app, ssl_options)
  18. server.listen(6790)
  19. tornado.ioloop.IOLoop.instance().set_blocking_log_threshold(0.5)
  20. tornado.ioloop.IOLoop.instance().start()
Add Comment
Please, Sign In to add comment