This commit is contained in:
黄心宇 2024-01-15 09:56:55 +08:00
parent 3874b65d5f
commit 5f8ddaadec
2 changed files with 17 additions and 1 deletions

16
build.bash Normal file
View File

@ -0,0 +1,16 @@
#!/bin/bash
# 确保脚本在当前目录执行
cd "$(dirname "$0")"
# 安装依赖
npm install
# 构建项目
npm run build
# 构建服务器端
npm run build:server
# 使用PM2启动应用程序
npm run pm2

View File

@ -9,6 +9,6 @@
"env": {
"NODE_ENV": "production"
},
"instances": 0
"instances": 4
}]
}