Merge pull request #1362 from filecoin-project/fix/no-storage-init
storageminer: Correctly initialize storage.json with --no-local-storage
This commit is contained in:
commit
f9c38ac35e
@ -200,11 +200,12 @@ var initCmd = &cli.Command{
|
||||
if err := ioutil.WriteFile(filepath.Join(lr.Path(), "sectorstore.json"), b, 0644); err != nil {
|
||||
return xerrors.Errorf("persisting storage metadata (%s): %w", filepath.Join(lr.Path(), "storage.json"), err)
|
||||
}
|
||||
|
||||
sc.StoragePaths = append(sc.StoragePaths, config.LocalPath{
|
||||
Path: lr.Path(),
|
||||
})
|
||||
}
|
||||
|
||||
sc.StoragePaths = append(sc.StoragePaths, config.LocalPath{
|
||||
Path: lr.Path(),
|
||||
})
|
||||
|
||||
if err := lr.SetStorage(sc); err != nil {
|
||||
return xerrors.Errorf("set storage config: %w", err)
|
||||
|
Loading…
Reference in New Issue
Block a user