diff options
author | Chocobozzz <me@florianbigard.com> | 2022-06-23 10:29:43 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2022-06-23 10:30:48 +0200 |
commit | 53023be33af420675d0060eb95c99a8038457564 (patch) | |
tree | 699a13694b0c1c8589d10de95184708a451fcab4 /server/initializers | |
parent | 50341c8fe988ca2a3d7c700f9aa918673dc979c2 (diff) | |
download | PeerTube-53023be33af420675d0060eb95c99a8038457564.tar.gz PeerTube-53023be33af420675d0060eb95c99a8038457564.tar.zst PeerTube-53023be33af420675d0060eb95c99a8038457564.zip |
Fix fast restream in saved permanent live
Diffstat (limited to 'server/initializers')
-rw-r--r-- | server/initializers/constants.ts | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/server/initializers/constants.ts b/server/initializers/constants.ts index 9201f95b3..6c6628d28 100644 --- a/server/initializers/constants.ts +++ b/server/initializers/constants.ts | |||
@@ -865,7 +865,7 @@ if (isTestInstance() === true) { | |||
865 | 865 | ||
866 | PLUGIN_EXTERNAL_AUTH_TOKEN_LIFETIME = 5000 | 866 | PLUGIN_EXTERNAL_AUTH_TOKEN_LIFETIME = 5000 |
867 | 867 | ||
868 | VIDEO_LIVE.CLEANUP_DELAY = 5000 | 868 | VIDEO_LIVE.CLEANUP_DELAY = getIntEnv('PEERTUBE_TEST_CONSTANTS.VIDEO_LIVE.CLEANUP_DELAY') ?? 5000 |
869 | VIDEO_LIVE.SEGMENT_TIME_SECONDS.DEFAULT_LATENCY = 2 | 869 | VIDEO_LIVE.SEGMENT_TIME_SECONDS.DEFAULT_LATENCY = 2 |
870 | VIDEO_LIVE.SEGMENT_TIME_SECONDS.SMALL_LATENCY = 1 | 870 | VIDEO_LIVE.SEGMENT_TIME_SECONDS.SMALL_LATENCY = 1 |
871 | VIDEO_LIVE.EDGE_LIVE_DELAY_SEGMENTS_NOTIFICATION = 1 | 871 | VIDEO_LIVE.EDGE_LIVE_DELAY_SEGMENTS_NOTIFICATION = 1 |
@@ -1174,3 +1174,9 @@ function buildLanguages () { | |||
1174 | function generateContentHash () { | 1174 | function generateContentHash () { |
1175 | return randomBytes(20).toString('hex') | 1175 | return randomBytes(20).toString('hex') |
1176 | } | 1176 | } |
1177 | |||
1178 | function getIntEnv (path: string) { | ||
1179 | if (process.env[path]) return parseInt(process.env[path]) | ||
1180 | |||
1181 | return undefined | ||
1182 | } | ||