Skip to content

Commit

Permalink
feat: 🚀 新增 pm2 配置用于部署 (#133)
Browse files Browse the repository at this point in the history
  • Loading branch information
xun082 authored Oct 29, 2024
1 parent 850dddb commit adfed2b
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 2 deletions.
12 changes: 12 additions & 0 deletions ecosystem.config.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
module.exports = {
apps: [
{
name: 'online_editor_web',
script: './node_modules/next/dist/bin/next',
args: 'start -p 3000',
instances: 1,
autorestart: true,
watch: false,
},
],
};
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
"format:ci": "prettier --list-different \"**/*.{ts,tsx,js,jsx}\"",
"test": "vitest",
"storybook": "storybook dev -p 6006",
"build-storybook": "storybook build"
"build-storybook": "storybook build",
"ps": "pm2 start ecosystem.config.cjs"
},
"keywords": [],
"author": "Moment",
Expand Down
3 changes: 2 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@
"**/*.tsx",
".next/types/**/*.ts",
"eslint.config.cjs",
".storybook/**/*"
".storybook/**/*",
"ecosystem.config.cjs"
],
"exclude": ["node_modules"]
}

0 comments on commit adfed2b

Please sign in to comment.