环境:centos7 nginx1.16.1
先将tp源代码下载到nginx目录下
tp放到/usr/local/nginx/目录下,root为相对路径,如:
tp在/usr/local/nginx/wwwroot/ 则 root wwwroot/public;
tp不再nginx目录,则使用alias 绝对路径指定,不需要root。
注意:存放tp的目录要有可执行权限,否则无法进入目录,访问报403
servr配置:
1 | server { |
缺失模块。
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