Flask WSGI: This is a development server

小豆苗 1年前 ⋅ 27872 阅读

WARNING: This is a development server. Do not use it in a production deployment. Falsk WSGI

 

两种方法:

方法一:

from gevent import pywsgi

if __name__ == '__main__':
server = pywsgi.WSGIServer(('0.0.0.0', 5000), app)
server.serve_forever()
方法二:

from wsgiref.simple_server import make_server

if __name__ == '__main__':
server = make_server('', 64570, app)
server.serve_forever()


全部评论: 0

    我有话说: