4bnode 4.1.1 → 4.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "4bnode",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.2",
|
|
4
4
|
"description": "4bnode is a CLI-powered backend development platform with a built-in visual dashboard to generate, manage, and test Node.js/Express APIs faster.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
// PM2 process config for production.
|
|
2
|
+
//
|
|
3
|
+
// pm2 start ecosystem.config.cjs # start (NODE_ENV=production)
|
|
4
|
+
// pm2 save # remember across reboots
|
|
5
|
+
// pm2 startup # enable boot startup (run the printed command)
|
|
6
|
+
// pm2 logs / pm2 restart / pm2 status
|
|
7
|
+
//
|
|
8
|
+
// NODE_ENV=production keeps the /_dev dashboard OFF and security on. Other config
|
|
9
|
+
// (PORT, MONGO_URI, secrets) comes from your .env. CommonJS (.cjs) on purpose —
|
|
10
|
+
// the app itself is an ES module.
|
|
11
|
+
const pkg = require("./package.json");
|
|
12
|
+
|
|
13
|
+
module.exports = {
|
|
14
|
+
apps: [
|
|
15
|
+
{
|
|
16
|
+
name: pkg.name || "app",
|
|
17
|
+
script: "index.js",
|
|
18
|
+
instances: 1,
|
|
19
|
+
autorestart: true,
|
|
20
|
+
env: {
|
|
21
|
+
NODE_ENV: "production",
|
|
22
|
+
},
|
|
23
|
+
},
|
|
24
|
+
],
|
|
25
|
+
};
|