ipfs-desktop icon indicating copy to clipboard operation
ipfs-desktop copied to clipboard

Mount MFS

Open hacdias opened this issue 7 years ago • 13 comments

Should IPFS Desktop allow the user to mount MFS to the file system or should this feature be incorporated into js-ipfs and go-ipfs?

@alanshaw has taken a step ahead and created a module to let us mount MFS.

I noticed there was another issue referencing something like this from 2015 (#154). I'll close that one and copy its content here to keep our discussion.

@almereyda (jon r) on Dec 23, 2015

As ipfs/go-ipfs:docs/fuse.md@master mentions, we can use the daemons --mount option to hook IPFS into the filesystem. As a station user, I want to be able to use the FUSE options as exposed via the config at http://127.0.0.1:5001/ipfs/QmR9MzChjp1MdFWik7NjEjqKQMzVmBkdK3dz14A6B5Cupm/#/config

Which scenario like this is supported by it? Maybe a checkbox below the "Start Node" button, which is only shown with manually stopping the deamon, may do?

/cc @ipfs-shipyard/ipfs-gui-team

hacdias avatar Mar 17 '18 11:03 hacdias

Not sure about low level implementation, but IPFS Desktop is a natural fit for UI responsible for enabling/disabling this.

It is worth highlighting that @alanshaw started work towards that goal:

  • https://github.com/tableflip/ipfs-fuse
    • Demo: "Mount IPFS MFS as a FUSE volume" https://youtu.be/jXkTEBdM6aA

lidel avatar Mar 17 '18 21:03 lidel

@lidel yeah, I was thinking about using that package to enable/disable the mounting.

hacdias avatar Mar 18 '18 09:03 hacdias

See also: https://github.com/piedar/js-ipfs-mount

lidel avatar Jul 28 '18 22:07 lidel

Uhhh, that's cool. I'll try and see if it works on Windows with Dokany

hacdias avatar Jul 29 '18 06:07 hacdias

Hey, @djdv IIRC last time we talked about this you mentioned mounting MFS will be a part of go-ipfs, is that still the case? Do you have any ideas on how we could integrate it with ipfs-desktop? Would it be a plugin, config key, cli parameter or something else?

lidel avatar Oct 18 '18 20:10 lidel

@lidel

mounting MFS will be a part of go-ipfs

At this time, yes!

Do you have any ideas on how we could integrate it with ipfs-desktop?

Since we're just exposing it as a writable filesystem, you should be able to interact with it in a standard way. I haven't nailed everything down yet, but in theory you should be able to parse the config to find the mountpoint, and add some wrapping around it.

You can see the status of the mount implimentation here: https://github.com/ipfs/go-ipfs/issues/5003 https://www.youtube.com/playlist?list=PLrZxGPqQuwHC_cZF2assuM0Vl3D5s5OSN

djdv avatar Oct 19 '18 09:10 djdv

@djdv just read the whole issue and I have to say that what I read is just amazing and the progress you've made is incredible. I can't wait to be able to easily mount MFS on Windows.

Just as a side note: I was wondering if it would be possible to have an IPFS implementation independent mount that would work with any IPFS implementation - via HTTP API or connecting directly maybe. The drawback I see here is that the connection might be a bit slower. Not sure. Needs thought.

hacdias avatar Oct 20 '18 18:10 hacdias

@djdv what's the state of MFS mount?

hacdias avatar Aug 07 '19 10:08 hacdias

@hacdias Current status is being tracked here: https://github.com/ipfs/package-managers/issues/74

At the moment I'm making an effort to develop versions of the concepts demoed before, in a way that can be merged into go-ipfs gradually. I'd like to have some kind of read support under an experimental flag ASAP.

I wrote a big summary here but the tl;dr is that above ^

djdv avatar Aug 07 '19 14:08 djdv

Current status is being tracked here: ipfs-inactive/package-managers#74

That repo has been archived:

I apologize to the community, to which I made promises I could not keep.

So what's next? Were these efforts continued, and where to track the status now?

bam80 avatar Mar 28 '21 15:03 bam80

I know it's just a drop in the bucket, but I'd be willing to chip in $150 into any kind of gittip/bounty/donation system towards this feature. A mutable FUSE mount for IPFS one of the biggest things I'm waiting for that would allow us to easily integrate IPFS everywhere in our internet archiving stack over at ArchiveBox.io.

pirate avatar Mar 29 '21 17:03 pirate

IIUC FUSE turned out to be pretty problematic part of go-ipfs, each platform/filesystem (linux, windows, macos) having own issues, making the entire thing too brittle for production use, and fixing myriad of fuse problems was stealing dev time and burning our devs in the process. It is unlikely to be fixed any time soon upstream.

That being said, if someone is brave enough to tackle this across all three platforms, PRs welcome. MFS mounting for desktop use does not need to be super performant nor a part of go-ipfs: ipfs-desktop is an electron app, so if someone can make it work in JS (perhaps by reusing prior art from Alan's demo), I'd be happy to help with review.

Personally, I'd like to see someone experiment with exposing MFS over WebDAV instead, which is HTTP-based and seems to be supported on Linux, macOS and Windows out of the box (in form of "mounting external drives").

lidel avatar Mar 30 '21 17:03 lidel

I have no particular love for FUSE either, NFS/SMB/WebDAV, any mountable mutable filesystem works for me. As long as it's mountable as a Docker volume or within docker somehow at the end of the day.

pirate avatar Mar 30 '21 18:03 pirate