/[sudobot]/trunk/ecosystem.config.js
ViewVC logotype

Contents of /trunk/ecosystem.config.js

Parent Directory Parent Directory | Revision Log Revision Log


Revision 575 - (show annotations)
Mon Jul 29 17:59:26 2024 UTC (8 months ago) by rakinar2
File MIME type: text/javascript
File size: 661 byte(s)
chore: add trunk
1 const { existsSync } = require("fs");
2 const { resolve } = require("path");
3
4 const logDirectoryExists = existsSync(resolve(__dirname, "logs"));
5
6 /**
7 * @type {import("@onesoftnet/pm2-config").PM2Config}
8 */
9 const config = {
10 apps: [
11 {
12 name: "sudobot",
13 script: "build/out/main.js",
14 env_production: {
15 NODE_ENV: "production"
16 },
17 autorestart: true,
18 log_date_format: "YYYY-MM-DD HH:mm:ss Z",
19 log_file: logDirectoryExists ? "logs/debug.log" : null,
20 error: logDirectoryExists ? "logs/error.log" : null
21 }
22 ]
23 };
24
25 module.exports = config;

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26