Fixed the transcode job to rename the output file to the proper extension
This commit is contained in:
parent
611d0dba9a
commit
076947ebf9
@ -6,6 +6,7 @@ import (
|
|||||||
"os"
|
"os"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
@ -58,7 +59,8 @@ func (t *Transcoder) Start() {
|
|||||||
func (t *Transcoder) Transcode(inFile string) {
|
func (t *Transcoder) Transcode(inFile string) {
|
||||||
// create ingest and archive paths
|
// create ingest and archive paths
|
||||||
ingestPath := filepath.Join(t.repo.GetIngestPath(), inFile)
|
ingestPath := filepath.Join(t.repo.GetIngestPath(), inFile)
|
||||||
outputPath := filepath.Join(t.repo.GetOutputPath(), inFile)
|
outputName := strings.Join([]string{util.FilenameWithoutExtension(inFile), viper.GetString("transcoder.video_format")}, ".")
|
||||||
|
outputPath := filepath.Join(t.repo.GetOutputPath(), outputName)
|
||||||
|
|
||||||
log.Printf("Transcoding video file %s.", ingestPath)
|
log.Printf("Transcoding video file %s.", ingestPath)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user