1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-06 03:50:26 +02:00

Fix HLS re transcoding with object storage enabled

This commit is contained in:
Chocobozzz 2022-02-01 14:19:44 +01:00
parent 0f11ec8dd3
commit a2caee9f51
No known key found for this signature in database
GPG key ID: 583A612D890159BE
6 changed files with 119 additions and 19 deletions

View file

@ -6,11 +6,9 @@ import { getHLSDirectory } from '../paths'
import { generateHLSObjectBaseStorageKey, generateHLSObjectStorageKey, generateWebTorrentObjectStorageKey } from './keys'
import { lTags, makeAvailable, removeObject, removePrefix, storeObject } from './shared'
function storeHLSFile (playlist: MStreamingPlaylistVideo, filename: string) {
const baseHlsDirectory = getHLSDirectory(playlist.Video)
function storeHLSFile (playlist: MStreamingPlaylistVideo, filename: string, path?: string) {
return storeObject({
inputPath: join(baseHlsDirectory, filename),
inputPath: path ?? join(getHLSDirectory(playlist.Video), filename),
objectStorageKey: generateHLSObjectStorageKey(playlist, filename),
bucketInfo: CONFIG.OBJECT_STORAGE.STREAMING_PLAYLISTS
})