winfsp / hubfs

File system for GitHub & GitLab
https://winfsp.dev
GNU Affero General Public License v3.0
1.62k stars 60 forks source link

Are all of these fs types used in hubfs? #9

Open lonnietc opened 1 year ago

lonnietc commented 1 year ago

Hello,

I was looking at the HUBFS as it might be what I need to use to learn from as a template to build out the unionized ssh type filesystem and was reviewing the code in the src/fs section of hubfs.

https://github.com/winfsp/hubfs/tree/master/src/fs

What is interesting is that the hubfs seems to utilize:

memfs nullfs overlayfs port ptfs (passthrough) unionfs

I was wondering if all of these are really used together.

Can you please elaborate more on how this works together since I would estimate that the "nullfs" is started initially until the user maps into github and then, just perhaps the unionfs is used to combine the different repositories that are under any given singe organization, or something along those lines.

Can you please help me understand the flow of things since as you know, I am interested in something similar, but to union mappings to different user accounts on separate ssh servers into a single R/W directory structure mounted.

Any information that you could provide would be greatly appreciated.

Happy Holidays and I look forward to hearing back from you. Thanks

billziss-gh commented 1 year ago

I think memfs is the only one that is not currently being used in HUBFS.

Look here to see how the various file systems are synthesized together:

https://github.com/winfsp/hubfs/blob/master/src/fs/hubfs/overlay.go#L48

lonnietc commented 1 year ago

Thanks for this information and I will see if I can get a feel for how it all comes together.