- NGINX Cookbook
- Tim Butler
- 116字
- 2021-07-03 00:04:30
How it works...
The Flask applications are so simple that they don't come with all of the boilerplate WSGI configurations such as Django and other frameworks. The good news is that the flexibility of uWSGI means it's very easy to configure.
In order for uWSGI to know what file to call, which we do via the module configuration entry, set it to demoapp. Those familiar with Python will know that this translates into loading demoapp.py.
Secondly, the callable configuration specifies the default WSGI callable name, which in our demoapp.py is set to application.
Lastly, we have a very simple NGINX server block directive. This simply pushes all calls to our Flask application using the uWSGI socket.
推薦閱讀
- Spring Cloud Alibaba核心技術與實戰案例
- Getting started with Google Guava
- Azure IoT Development Cookbook
- Java入門很輕松(微課超值版)
- Reactive Programming with Swift
- SharePoint Development with the SharePoint Framework
- C++新經典
- Python Interviews
- Python數據可視化之美:專業圖表繪制指南(全彩)
- 自己動手構建編程語言:如何設計編譯器、解釋器和DSL
- Python全棧開發:數據分析
- R語言數據分析從入門到實戰
- Three.js Essentials
- 深入理解Zabbix監控系統
- 區塊鏈原理、設計與應用