增强:配合nginx前置,可以记录登录用户的原始IP而不是nginx服务器的IP。

pull/105/head
Apex Liu 2018-05-09 16:29:16 +08:00
parent 50d814869c
commit 0a3c99dc05
1 changed files with 1 additions and 1 deletions

View File

@ -149,7 +149,7 @@ class WebApp:
fix_controller()
_app = tornado.web.Application(controllers, **settings)
server = tornado.httpserver.HTTPServer(_app)
server = tornado.httpserver.HTTPServer(_app, xheaders=True)
# server = tornado.httpserver.HTTPServer(_app, ssl_options={
# "certfile": os.path.join(cfg.data_path, 'cert', "server.pem"),
# "keyfile": os.path.join(cfg.data_path, 'cert', "server.key"),