This repository has been archived by the owner on Dec 11, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathecosystem.config.example.js
127 lines (103 loc) · 3.5 KB
/
ecosystem.config.example.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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
const logsDir = process.cwd() + '/logs'
module.exports = {
apps: [
{
name: 'GraphQL API',
cwd: 'apis/graphql-api',
script: 'dist/src/main.js',
instances: 1,
max_restarts: 5,
autorestart: true,
watch: false,
error_file: `${logsDir}/graphql-api.log`,
out_file: `${logsDir}/graphql-api.log`,
log_file: null,
env: {
NODE_ENV: 'production',
// Port to run this server on, when changing this one a new Android app must be build with that port
PORT: 5000,
// The name of the MongoDB database
MONGO_DATABASE: 'popcorn-api-development',
// The URI to the MongoDB database.
MONGO_URI: '127.0.0.1',
// The port of the MongoDB database.
MONGO_PORT: '27017',
// The username of the MongoDB database, disable if none.
// MONGO_USER: '',
// The password of the MongoDB database, disable if none.
// MONGO_PASS: '',
// The url to the scraper
SCRAPER_URL: 'http://localhost:5001',
// Location where to download everything in, make sure this location exists
// Also must be a absolute path
DOWNLOAD_LOCATION: '',
// Username of your opensubtitles account
// OPENSUBTITLES_USERNAME: '',
// Password of your opensubtitles account
// OPENSUBTITLES_PASSWORD: ''
},
},
{
name: 'Scraper',
cwd: 'apis/scraper',
script: 'dist/scraper.js',
args: '-m pretty',
instances: 1,
max_restarts: 5,
autorestart: true,
watch: false,
error_file: `${logsDir}/scraper.log`,
out_file: `${logsDir}/scraper.log`,
log_file: null,
env: {
NODE_ENV: 'production',
// The port the API wil be running on.
PORT: 5001,
// The name of the MongoDB database
MONGO_DATABASE: 'popcorn-api',
// The URI to the MongoDB database.
MONGO_URI: '127.0.0.1',
// The port of the MongoDB database.
MONGO_PORT: '27017',
// The username of the MongoDB database, disable if none.
// MONGO_USER: '',
// The password of the MongoDB database, disable if none.
// MONGO_PASS: '',
// The time between cronjobs.
CRON_TIME: '0 0 */6 * * *',
// The location of the temporary directory for the logs.
TEMP_DIR: `${logsDir}/`,
// API key for Fanart, get one here: https://fanart.tv/get-an-api-key/
FANART_KEY: '',
// API key for Omdb, get one here: http://www.omdbapi.com/apikey.aspx
OMDB_KEY: '',
// API key for Tmdb, get one here: https://www.themoviedb.org/settings/api/new/form?type=developer
TMDB_KEY: '',
// API key for Trakt, get one here: https://trakt.tv/oauth/applications/new (Use the client id)
TRAKT_KEY: '',
// API key for Tvdb, get one here: https://www.thetvdb.com/member/api
TVDB_KEY: '',
},
},
// Enable this if you want auto updates
// {
// name: 'Updater',
// cwd: 'updater',
// script: 'dist/updater.js',
// instances: 1,
// max_restarts: 5,
// autorestart: true,
// watch: false,
// error_file: `${logsDir}/updater.log`,
// out_file: `${logsDir}/updater.log`,
// log_file: null,
// env: {
// // The time between cronjobs.
// CRON_TIME: '0 0 * * *',
//
// // Location of the getting-started project
// PROJECT_LOCATION: '',
// },
// },
],
}