diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 09b784c0..1bb56d14 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -32,7 +32,7 @@ jobs: strategy: fail-fast: false matrix: - node-version: [16, 18] + node-version: [16, 18, 20] os: [ubuntu-latest] steps: @@ -83,7 +83,7 @@ jobs: strategy: fail-fast: false matrix: - node-version: [16, 18] + node-version: [16, 18, 20] os: [ubuntu-latest] steps: diff --git a/config/plugin.ts b/config/plugin.ts index d07ac082..f464ffbf 100644 --- a/config/plugin.ts +++ b/config/plugin.ts @@ -52,6 +52,10 @@ const plugin: EggPlugin = { enable: true, package: 'egg-cors', }, + status: { + enable: true, + package: 'egg-status', + }, }; export default plugin; diff --git a/package.json b/package.json index e4634bcf..40a530be 100644 --- a/package.json +++ b/package.json @@ -51,8 +51,8 @@ "tsc": "npm run clean && tsc -p ./tsconfig.json", "tsc:prod": "npm run clean && tsc -p ./tsconfig.prod.json", "prepublishOnly": "npm run tsc:prod", - "start": "eggctl start --daemon", - "stop": "eggctl stop" + "start": "eggctl start --daemon && touch egg.status", + "stop": "rm -f egg.status && sleep 15 && eggctl stop" }, "repository": { "type": "git", @@ -88,6 +88,7 @@ "egg-errors": "^2.3.0", "egg-redis": "^2.4.0", "egg-scripts": "^2.15.2", + "egg-status": "^1.0.0", "egg-tracer": "^1.1.0", "egg-typebox-validate": "^2.0.0", "egg-view-nunjucks": "^2.3.0",