ecosystem.config.js
module.exports = {
apps : [{
name: "app",
script: "./app.js",
env: {
NODE_ENV: "development",
},
env_production: {
NODE_ENV: "production",
}
}]
}
# $ pm2 [start|restart|stop|delete] ecosystem.config.js
$ pm2 start ecosystem.config.js
https://doc.pm2.io/en/runtime/guide/ecosystem-file/
https://pm2.keymetrics.io/docs/usage/application-declaration/
$ yarn global add pm2
# OR
$ npm install pm2 -g
# global
$ pm2 start server/index.js
$ yarn add -D pm2
# OR
$ npm i -D pm2
# local
$ ./node_modules/pm2/bin/pm2 start server/index.js
$ ./node_modules/pm2/bin/pm2 list
# $ ./node_modules/pm2/bin/pm2 stop ID
$ ./node_modules/pm2/bin/pm2 stop 0
$ ./node_modules/pm2/bin/pm2 monit
https://pm2.keymetrics.io/docs/usage/application-declaration/
sequelize-cli
https://github.com/sequelize/sequelize
Object Relational Mapping 对象关系映射
Table => Object, 简化 SQL 查询命令的编写
https://en.wikipedia.org/wiki/Object-relational_mapping
https://stackoverflow.com/questions/1279613/what-is-an-orm-how-does-it-work-and-how-should-i-use-one
https://www.cnblogs.com/xgqfrms/p/13621076.html
xgqfrms 2012-2020
www.cnblogs.com 发布文章使用:只允许注册用户才可以访问!
手机扫一扫
移动阅读更方便
你可能感兴趣的文章