X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=shared%2Fextra-utils%2Fvideos%2Flive.ts;h=c0384769bda247f4dc13ce8a38d70ac2c8879259;hb=d4a8e7a65f97bb3257facc13e1ae8ffdbad61ddb;hp=d3cd974de81d3226a62e4672108f4a8e1302c3e0;hpb=4024c44f9027a32809931de0692d40d001df721c;p=github%2FChocobozzz%2FPeerTube.git diff --git a/shared/extra-utils/videos/live.ts b/shared/extra-utils/videos/live.ts index d3cd974de..c0384769b 100644 --- a/shared/extra-utils/videos/live.ts +++ b/shared/extra-utils/videos/live.ts @@ -175,6 +175,12 @@ async function waitUntilLiveSaved (url: string, token: string, videoId: number | } while (video.isLive === true && video.state.id !== VideoState.PUBLISHED) } +async function waitUntilLivePublishedOnAllServers (servers: ServerInfo[], videoId: string) { + for (const server of servers) { + await waitUntilLivePublished(server.url, server.accessToken, videoId) + } +} + async function checkLiveCleanup (server: ServerInfo, videoUUID: string, resolutions: number[] = []) { const basePath = buildServerDirectory(server, 'streaming-playlists') const hlsPath = join(basePath, 'hls', videoUUID) @@ -226,6 +232,7 @@ export { sendRTMPStreamInVideo, waitUntilLiveEnded, waitFfmpegUntilError, + waitUntilLivePublishedOnAllServers, sendRTMPStream, testFfmpegStreamError }