-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(miner deals): create subdir to miner repo for staged deals #6853
Conversation
3014d8a
to
a229b5e
Compare
@@ -607,7 +607,7 @@ func StorageProvider(minerAddress dtypes.MinerAddress, | |||
df dtypes.StorageDealFilter, | |||
) (storagemarket.StorageProvider, error) { | |||
net := smnet.NewFromLibp2pHost(h) | |||
store, err := piecefilestore.NewLocalFileStore(piecefilestore.OsPath(r.Path())) | |||
store, err := piecefilestore.NewLocalFileStore(piecefilestore.OsPath(filepath.Join(r.Path(), "deal-staging"))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The next steps could be to make this path value configurable via the miner config (I'm sure this would make @travisperson's life a bit easier). If we think it's worth doing I can add it in. Doing this work will also close: #5591
// this is required due to the method makeDealStaging from cmd/lotus-storage-miner/init.go | ||
// deal-staging is the directory deal files are staged in before being sealed into sectors | ||
// for offline deal flow. | ||
if err := os.MkdirAll(filepath.Join(t, "deal-staging"), 0755); err != nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is kinda ugly, but I didn't want to make the Repo responsible for creating this directory since it is used by things other than the miner.
a229b5e
to
ca697c9
Compare
Closes #5291