Skip to content
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

A decision to make #6

Open
makew0rld opened this issue Nov 15, 2018 · 4 comments
Open

A decision to make #6

makew0rld opened this issue Nov 15, 2018 · 4 comments
Labels
enhancement New feature or request

Comments

@makew0rld
Copy link
Owner

makew0rld commented Nov 15, 2018

It seems to me that there are two ways I can go with this fork of Forban: shared LAN directory, or separated file-sharing. The problem is that Forban seems to straddle both, with a separated mindset internally and on the web ui, but a shared directory mindset within ./var/share. I'd like to "pick one and do it well" instead.

Shared LAN Directory

All nodes contribute to one folder that gets replicated across the LAN (or direct cjdns peers). It doesn't matter where the files come from, and everyone can edit and delete everything. It's versioned on a per file basis though.

Separated File-Sharing

In every possible space, the files that are shared are separated into folders based on device (uuid). They cannot be changed or edited except by the original sharer, but they can propagate through the network through other nodes. Versioned as well.

@makew0rld makew0rld added the enhancement New feature or request label Nov 15, 2018
@makew0rld
Copy link
Owner Author

Shared LAN Directory doesn't really seem to be compatible with the "shared" mode, it only works when there's some degree of separation.

@makew0rld
Copy link
Owner Author

makew0rld commented Nov 16, 2018

I have to consider my use case as well. A lot of decentralized file sharing use cases are handled by IPFS in the @tomeshnet stack, and so I don't want to overlap. The best use case to me seems to be the Shared LAN Directory, as it allows for speedy file transfer for debugging or other purposes in a trust everyone network, like at our meetings.

@makew0rld
Copy link
Owner Author

makew0rld commented Nov 16, 2018

Roadmap for switching to Shared LAN Directory

  • Stop recording which file came from which node
  • Don't keep indexes for every node
    • Just keep one local index
    • Go through remote indexes and download files that aren't listed in the local index
    • Then add them to the local index
  • Add folder structure as mentioned in Only files are listed -- and only they are shared #5
  • Remake web ui to just display the global folder, and open files when clicked
    • It could also display some statistics, about known nodes, etc
  • Versioning

Smaller things to do

  • Reformat all adulau code according to PEP8
  • Figure out if hmacs are still needed
  • Change forban; part of protocol so as not to interfere with the original version
  • Change port from 12555 to 12777 for the same reason
  • Change repo name, description, README, docs
  • Change user-agent header as described in lib/fetch.py and possibly other places.
  • Remove the stupid headers on every single file

@makew0rld
Copy link
Owner Author

makew0rld commented Dec 14, 2018

In an effort to clean up the codebase, and as fun exercise, I would like to entirely rewrite this application for my own purposes as listed above, using this repo / the original Forban repo as a reference. One day, I'll learn go and rewrite it in that, too...

  • New repo
  • New name (LAN-Folder)
  • Python 3 instead of Python 2
  • Following PEP8 styleguide
  • Hopefully it will be organized better file-wise

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant