Autoseed buckets pendant serverCmd
This commit is contained in:
parent
3891ea36ca
commit
03cef363cd
1 changed files with 12 additions and 0 deletions
|
@ -46,6 +46,18 @@ var serverCmd = &cobra.Command{
|
|||
log.Fatal(err)
|
||||
}
|
||||
|
||||
mediaClient, err := media.NewMediaClientFromViper()
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
|
||||
new_buckets, err := mediaClient.Seed()
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
|
||||
log.Printf("Seeded %d buckets.\n", len(new_buckets))
|
||||
|
||||
RunServer()
|
||||
},
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue