Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
Add pm2 yapi service manage
  • Loading branch information
redhatxl authored Aug 17, 2019
1 parent cbdba1c commit a1e0199
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,20 @@ YApi 是<strong>高效</strong>、<strong>易用</strong>、<strong>功能强大

npm install -g yapi-cli --registry https://registry.npm.taobao.org
yapi server

#### 服务管理
利用pm2方便服务管理维护

npm install pm2 -g //安装pm2
cd {项目目录}
pm2 start "vendors/server/app.js" --name yapi //pm2管理yapi服务
pm2 info yapi //查看服务信息
pm2 stop yapi //停止服务
pm2 restart yapi //重启服务

#### 升级
升级项目版本是非常容易的,并且不会影响已有的项目数据,只会同步 vendors 目录下的源码文件。

cd {项目目录}
yapi ls //查看版本号列表
yapi update //更新到最新版本
Expand Down

0 comments on commit a1e0199

Please sign in to comment.