Fixed segment cleanup deleting init.mp4 and reduced its cache duration to 20 seconds.
Automated API tests / test (push) Failing after 5s
Browser Tests / cypress-run (push) Failing after 5s
Lint / Go linter (push) Failing after 4s
HLS tests / tests (push) Failing after 5s
Go Tests / test (push) Has been cancelled
Go Tests / test-bsds (map[name:freebsd version:12.2]) (push) Has been cancelled
Go Tests / test-bsds (map[name:openbsd version:6.8]) (push) Has been cancelled
Automated API tests / test (push) Failing after 5s
Browser Tests / cypress-run (push) Failing after 5s
Lint / Go linter (push) Failing after 4s
HLS tests / tests (push) Failing after 5s
Go Tests / test (push) Has been cancelled
Go Tests / test-bsds (map[name:freebsd version:12.2]) (push) Has been cancelled
Go Tests / test-bsds (map[name:openbsd version:6.8]) (push) Has been cancelled
This commit is contained in:
@@ -82,7 +82,7 @@ func getAllFilesRecursive(baseDirectory string) (map[string][]os.FileInfo, error
|
||||
directory = info.Name()
|
||||
}
|
||||
|
||||
if filepath.Ext(info.Name()) == ".m4s" || filepath.Ext(info.Name()) == ".mp4" {
|
||||
if filepath.Ext(info.Name()) == ".m4s" {
|
||||
files[directory] = append(files[directory], info)
|
||||
}
|
||||
|
||||
|
||||
@@ -317,7 +317,7 @@ func (s *S3Storage) retrieveAllVideoSegments() ([]s3object, error) {
|
||||
err := s.s3Client.ListObjectsPages(allObjectsListRequest,
|
||||
func(page *s3.ListObjectsOutput, lastPage bool) bool {
|
||||
for _, item := range page.Contents {
|
||||
if strings.HasSuffix(*item.Key, ".m4s") || strings.HasSuffix(*item.Key, ".mp4") {
|
||||
if strings.HasSuffix(*item.Key, ".m4s") {
|
||||
allObjects = append(allObjects, s3object{
|
||||
key: *item.Key,
|
||||
lastModified: *item.LastModified,
|
||||
|
||||
Vendored
BIN
Binary file not shown.
+1
-1
@@ -215,7 +215,7 @@ func GetCacheDurationSecondsForPath(filePath string) int {
|
||||
|
||||
defaultDaysCached := 30
|
||||
|
||||
if filename == "thumbnail.jpg" || filename == "preview.gif" {
|
||||
if filename == "thumbnail.jpg" || filename == "preview.gif" || filename == "init.mp4" {
|
||||
// Thumbnails & preview gif re-generate during live
|
||||
return 20
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user