Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
252a7b23aa | ||
|
0a4d9c4452 | ||
|
6939823646 | ||
|
60503e87ed | ||
|
2f732b6dcc | ||
|
1f999d1c3c |
@ -52,6 +52,7 @@ RUN apk update \
|
||||
&& mkdir /public
|
||||
COPY start.sh $WORKDIR
|
||||
COPY serve.json $WORKDIR
|
||||
COPY pm2.config.js $WORKDIR
|
||||
RUN chmod +x "$START_SCRIPT" \
|
||||
&& apk del git curl \
|
||||
&& rm -rf /var/cache/apk/*
|
||||
|
14
README.md
14
README.md
@ -197,4 +197,16 @@ Sometimes a new version of this image will be bound to the same source commit. T
|
||||
- 1.0.52
|
||||
[02-18-2025](https://github.com/iptv-org/epg/commit/39c4c5143e7cf7591ac49227e73e564be70c7615)
|
||||
- 1.0.53
|
||||
[02-23-2025](https://github.com/iptv-org/epg/commit/2721fe1ba06761fd06799a233dda27af6184fd17)
|
||||
[02-23-2025](https://github.com/iptv-org/epg/commit/2721fe1ba06761fd06799a233dda27af6184fd17)
|
||||
- 1.0.54
|
||||
[03-07-2025](https://github.com/iptv-org/epg/commit/40c9af82d6f7f4e562cd239237fdf46a396d5728)
|
||||
- 1.0.55
|
||||
[03-11-2025](https://github.com/iptv-org/epg/commit/40c9af82d6f7f4e562cd239237fdf46a396d5728)
|
||||
- 1.0.56
|
||||
[03-16-2025](https://github.com/iptv-org/epg/commit/cf82b4089ef00c1fc94b7751652bfa598f8ab06a)
|
||||
- 1.0.57
|
||||
[03-25-2025](https://github.com/iptv-org/epg/commit/138842009bb3f9135430cdc667502ffa51d4a295)
|
||||
- 1.0.58
|
||||
[04-04-2025](https://github.com/iptv-org/epg/commit/4df25c92bcad1e4892640f532eae71cf9f5e7b95)
|
||||
- 1.0.59
|
||||
[04-04-2025](https://github.com/iptv-org/epg/commit/4df25c92bcad1e4892640f532eae71cf9f5e7b95)<br>Includes fixes for new configuration changes
|
23
pm2.config.js
Normal file
23
pm2.config.js
Normal file
@ -0,0 +1,23 @@
|
||||
module.exports = {
|
||||
apps: [
|
||||
{
|
||||
name: 'serve',
|
||||
script: 'npx serve -- public',
|
||||
instances: 1,
|
||||
watch: false,
|
||||
autorestart: true
|
||||
},
|
||||
{
|
||||
name: 'grab',
|
||||
script: process.env.SITE
|
||||
? `npm run grab -- --site=${process.env.SITE} ${
|
||||
process.env.CLANG ? `--lang=${process.env.CLANG}` : ''
|
||||
} --output=public/guide.xml`
|
||||
: `npm run grab -- --gzip --channels=channels.xml --output=public/guide.xml`,
|
||||
cron_restart: process.env.CRON || null,
|
||||
instances: 1,
|
||||
watch: false,
|
||||
autorestart: false
|
||||
}
|
||||
]
|
||||
}
|
7
start.sh
7
start.sh
@ -8,7 +8,7 @@ for arg in "$@"; do
|
||||
days=*) days="${arg#*=}" ;;
|
||||
max_connections=*) max_connections="${arg#*=}" ;;
|
||||
enable_fixes=*) enable_fixes="${arg#*=}" ;;
|
||||
api_url=*) api_url="${arg#*=}" ;;
|
||||
api_url=*) api_url="${arg#*=}" ;;
|
||||
esac
|
||||
done
|
||||
|
||||
@ -25,9 +25,6 @@ if [ "$enable_fixes" = true ] ; then
|
||||
fi
|
||||
|
||||
sed -i -E "s/(https:\x2f\x2fiptv-org.github.io\x2fapi$\123filename\125)/$api_url$\123filename\125/g" $work_dir/scripts/core/apiClient.ts
|
||||
|
||||
pm2 --name epg start npm -- run serve
|
||||
npm run grab --- --channels=channels.xml --maxConnections=$max_connections --days=$days --gzip
|
||||
ln -s $work_dir/guide.xml /public/guide.xml
|
||||
ln -s $work_dir/guide.xml.gz /public/guide.xml.gz
|
||||
npm run grab --- --channels=channels.xml --cron="$chron_schedule" --maxConnections=$max_connections --days=$days --gzip
|
||||
pm2-runtime pm2.config.js --name epg --node-args="--no-autorestart --cron-restart="$chron_schedule" --maxConnections=$max_connections --days=$days"
|
Loading…
x
Reference in New Issue
Block a user