Visual interface management platform Yapi installation and deployment

Posted May 27, 20201 min read

Download

mkdir/yapi
cd/yapi
git clone https://github.com/YMFE/yapi.git vendors
cp vendors/config_example.json ./config.json

Modify the configuration file config.json

vim config.json

Installation(Initialization)

cd vendors
npm install --production --registry https://registry.npm.taobao.org
node server/install.js

start up

node server/app.js

operation result
WX20200527-160336.png

Configure Nginx proxy

server {
    listen 80;
    server_name yapi.xxx.com;

    location/{
        proxy_pass http://127.0.0.1:3030/;
    }
}

Note:3030 is a note filled in config.js

Install pm2 process management tool(let service run in background)

npm install -g pm2
pm2 start app.js

References

Interface Document Artifact YApi
YApi official website description document-interface operation
Three methods of continuous running of the nodejs service background

Related Posts