写在前面
最近要将做的一个flask的项目部署到服务器上,找了一些方案,最终选定uwsgi+nginx,目前搭建成功了,接下来准备采用supervisor来管理服务进程。
1. 基础准备
- Linux服务器
- python
- uwsgi
- nginx
2. 部署步骤
a. 进入项目目录,配置python环境
| 
 | 
 | 
b. 接下来创建uwsgi的配置文件config.ini
| 
 | 
 | 
c. 接下来配置nginx进行反向代理
| 
 | 
 | 
d. 访问网站http://192.168.0.172
 
		
		
		  小小程序员
            缺失模块。
1、请确保node版本大于6.2
2、在博客根目录(注意不是yilia根目录)执行以下命令:
 npm i hexo-generator-json-content --save
            3、在根目录_config.yml里添加配置:
  jsonContent:
    meta: false
    pages: false
    posts:
      title: true
      date: true
      path: true
      text: false
      raw: false
      content: false
      slug: false
      updated: false
      comments: false
      link: false
      permalink: false
      excerpt: false
      categories: false
      tags: true