-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdev.config.js
64 lines (62 loc) · 1.98 KB
/
dev.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
/**
* If you are running in development mode, make sure you add JSON-RPC credentials to a .env file so that the environment variables are recorded by PM2
*/
require('dotenv').config();
module.exports = {
apps: [
{
name: 'scraper',
script: './src/services/scraper/index.scraper.ts',
watch: false,
interpreter: './node_modules/.bin/ts-node',
node_args: '-r tsconfig-paths/register ./src/services/scraper/index.scraper.ts',
env: {
SERVICE_NAME: 'scraper',
SERVICE_PORT: '5000',
NODE_ENV: 'development',
JSON_RPC_HTTP: process.env.JSON_RPC_HTTP,
JSON_RPC_WS: process.env.JSON_RPC_WS,
DB_HOST: process.env.DB_HOST || 'db',
CACHE_HOST: process.env.CACHE_HOST || 'cache',
},
max_restarts: 10,
restart_delay: 5000,
},
{
name: 'core',
script: './src/services/core/index.core.ts',
watch: false,
interpreter: './node_modules/.bin/ts-node',
node_args: '-r tsconfig-paths/register ./src/services/core/index.core.ts',
env: {
SERVICE_NAME: 'core',
SERVICE_PORT: '5001',
NODE_ENV: 'development',
JSON_RPC_HTTP: process.env.JSON_RPC_HTTP,
JSON_RPC_WS: process.env.JSON_RPC_WS,
USER_NAME: process.env.USER_NAME,
DATABASE_NAME: process.env.DATABASE_NAME,
DB_HOST: process.env.DB_HOST || 'db',
CACHE_HOST: process.env.CACHE_HOST || 'cache',
},
max_restarts: 10,
restart_delay: 5000,
},
{
name: 'api',
script: './src/services/api/index.api.ts',
watch: false,
interpreter: './node_modules/.bin/ts-node',
node_args: '-r tsconfig-paths/register ./src/services/api/index.api.ts',
env: {
SERVICE_NAME: 'api',
SERVICE_PORT: '5002',
NODE_ENV: 'development',
DB_HOST: process.env.DB_HOST || 'db',
CACHE_HOST: process.env.CACHE_HOST || 'cache',
},
max_restarts: 10,
restart_delay: 5000,
},
],
};