PM2 官方文档


安装

apt-get install npm
npm install pm2 -g

使用

pm2 start --name recorder "/root/live/BililiveRecorder.Cli run '/mnt/bilibili'"

查看和控制运行状态

pm2 ps

# "recorder" 是上面运行 pm2 start 时传入的 --name 参数
pm2 start recorder
pm2 stop recorder
pm2 restart recorder

pm2 logs recorder

pm2 delete recorder

preView