Set new FFmpeg version in process config during migration

This commit is contained in:
Ingo Oppermann
2022-11-09 11:35:47 +01:00
parent 2936bf1e80
commit 6f36f1aa51
3 changed files with 4 additions and 0 deletions

1
.gitignore vendored
View File

@@ -2,6 +2,7 @@
.env .env
/core* /core*
/import* /import*
/ffmigrate*
/data/** /data/**
/test/** /test/**
.vscode .vscode

View File

@@ -129,6 +129,8 @@ func doMigration(logger log.Logger, configstore cfgstore.Store) error {
reRTSP := regexp.MustCompile(`^rtsps?://`) reRTSP := regexp.MustCompile(`^rtsps?://`)
for id, p := range data.Process { for id, p := range data.Process {
logger.Info().WithField("processid", p.ID).Log("")
for index, input := range p.Config.Input { for index, input := range p.Config.Input {
if !reRTSP.MatchString(input.Address) { if !reRTSP.MatchString(input.Address) {
continue continue
@@ -144,6 +146,7 @@ func doMigration(logger log.Logger, configstore cfgstore.Store) error {
p.Config.Input[index] = input p.Config.Input[index] = input
} }
p.Config.FFVersion = version.String()
data.Process[id] = p data.Process[id] = p
} }

BIN
ffmigrate

Binary file not shown.