mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-11 01:20:08 -04:00
Update pm2.config.js
This commit is contained in:
parent
7fee216cb1
commit
6e2a814487
1 changed files with 2 additions and 14 deletions
|
@ -1,15 +1,3 @@
|
||||||
const grabArgs = [
|
|
||||||
'--channels=channels.xml',
|
|
||||||
'--output=public/guide.xml',
|
|
||||||
process.env.MAX_CONNECTIONS ? `--maxConnections=${process.env.MAX_CONNECTIONS}` : null,
|
|
||||||
process.env.TIMEOUT ? `--timeout=${process.env.TIMEOUT}` : null,
|
|
||||||
process.env.DELAY ? `--delay=${process.env.DELAY}` : null,
|
|
||||||
process.env.DAYS ? `--days=${process.env.DAYS}` : null,
|
|
||||||
process.env.GZIP === 'true' ? '--gzip' : null
|
|
||||||
]
|
|
||||||
.filter(Boolean)
|
|
||||||
.join(' ')
|
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
apps: [
|
apps: [
|
||||||
{
|
{
|
||||||
|
@ -21,8 +9,8 @@ module.exports = {
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'grab',
|
name: 'grab',
|
||||||
script: `npm run grab -- ${grabArgs}`,
|
script: `npm run grab -- --channels=channels.xml --output=public/guide.xml`,
|
||||||
cron_restart: process.env.CRON_SCHEDULE,
|
cron_restart: process.env.CRON || null,
|
||||||
instances: 1,
|
instances: 1,
|
||||||
watch: false,
|
watch: false,
|
||||||
autorestart: false
|
autorestart: false
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue