mirror of
https://github.com/portainer/portainer.git
synced 2025-08-05 13:55:21 +02:00
fix(migrator): fix setting version struct fields after migration [EE-4613] (#8090)
* fix setting version struct fields * fix go tests * remove versionUpdateRequired * remove old code that was originally for debugging purposes
This commit is contained in:
parent
d78b762f7b
commit
95bc508462
3 changed files with 20 additions and 32 deletions
|
@ -8,7 +8,6 @@ import (
|
|||
"path"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/portainer/libhelm"
|
||||
portainer "github.com/portainer/portainer/api"
|
||||
|
@ -142,15 +141,6 @@ func initDataStore(flags *portainer.CLIFlags, secretKey []byte, fileService port
|
|||
go func() {
|
||||
<-shutdownCtx.Done()
|
||||
defer connection.Close()
|
||||
|
||||
exportFilename := path.Join(*flags.Data, fmt.Sprintf("export-%d.json", time.Now().Unix()))
|
||||
|
||||
err := store.Export(exportFilename)
|
||||
if err != nil {
|
||||
log.Error().Str("filename", exportFilename).Err(err).Msg("failed to export")
|
||||
} else {
|
||||
log.Debug().Str("filename", exportFilename).Msg("exported")
|
||||
}
|
||||
}()
|
||||
|
||||
return store
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue