首页 > 解决方案 > “环境:生产”对 python-eve 意味着什么?

问题描述

我按照快速入门指南创建了一个简单的 Eve 应用程序。在控制台中,我看到了以下消息。

 * Serving Flask app "eve" (lazy loading)
 * Environment: production
   WARNING: This is a development server. Do not use it in a production deployment.
   Use a production WSGI server instead.
 ...

我检查了文档的开发/生产部分,但可以找到任何提到该Environment设置的地方。更具体地说,我无法弄清楚:

标签: pythonflaskeve

解决方案


Flask comes with a built-in web server to allow you to test your work but it is not secure or robust enough to run a live system that will be exposed to the public. For that you should deploy your Flask app using a full-strength server. Instructions are available on the Flask website. Personally I like Gunicorn.

https://flask.palletsprojects.com/en/1.1.x/deploying/wsgi-standalone/


推荐阅读