blob: 12acb3aec64e736e3102bdf2dc7a7e5e0ea7fade (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
import { join } from 'path'
import { MStreamingPlaylist, MVideoUUID } from '@server/types/models'
function generateHLSObjectStorageKey (playlist: MStreamingPlaylist, video: MVideoUUID, filename: string) {
return join(generateHLSObjectBaseStorageKey(playlist, video), filename)
}
function generateHLSObjectBaseStorageKey (playlist: MStreamingPlaylist, video: MVideoUUID) {
return join(playlist.getStringType(), video.uuid)
}
function generateWebTorrentObjectStorageKey (filename: string) {
return filename
}
export {
generateHLSObjectStorageKey,
generateHLSObjectBaseStorageKey,
generateWebTorrentObjectStorageKey
}
|