问题描述
因此,基本上,我打开了世界的端口443,并使用简单的套接字服务器对其进行了检查,并且该端口正常工作。但是当我运行uwsgi服务器时,它在此端口上的https上不起作用。但它确实可以在80端口的http中工作。 cheroot uwsgi是否需要在https服务中打开另一个端口,还是在https模式下由于某种原因而只是阻止外部连接。必须说它在本地连接中完美工作
这是我的代码
from cheroot.wsgi import Server as WsgiServer
from cheroot.wsgi import PathInfodispatcher as
WsgiPathInfodispatcher
from cheroot.ssl.builtin import BuiltinSSLAdapter
from MyFlaskApp import app
my_app = WsgiPathInfodispatcher({'/': app})
server = WsgiServer(('0.0.0.0',443),my_app)
ssl_cert = "[path]/myapp.crt"
ssl_key = "[path]/myapp.key"
server.ssl_adapter = BuiltinSSLAdapter(ssl_cert,ssl_key,None)
if __name__ == '__main__':
try:
server.start()
except KeyboardInterrupt:
server.stop()
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)