chr15m / bugout

Back end web app services over WebRTC.
https://chr15m.github.io/bugout
MIT License
604 stars 59 forks source link

Existing torrent #36

Closed btimby closed 3 years ago

btimby commented 3 years ago

Hi,

I am interested in adding Bugout RPC / gossip protocol capabilities to an existing application.

I am already using WebTorrent and seeding a torrent. Thus I would like to initialize Bugout with my torrent, adding the protocol extensions to the swarm.

I am correct that this would work? Can Bugout be used in conjunction with an existing seeding torrent?

I plan to make a PR that changes the Bugout ctor to accept a torrent instance, in a fashion similar to how it accepts an optional WebTorrent (client) instance.

FWIW, I am working on a solution much like Bugout with the following differences:

So the workflow is:

  1. Build or download an app bundle.
  2. Open browser, click extension icon, select "serve application"
  3. Browse to app bundle.
  4. Copy provided link and paste it to web sites or an email message etc like normal.

Users must also have the extension installed to visit the link.

I currently have a working prototype, the browser extension works in Firefox, Chrome and Opera (probably others too).

Web Underground (working title): https://github.com/btimby/ug

chr15m commented 3 years ago

Sounds awesome! Yes, I'll merge a PR that adds Bugout to an existing torrent. The library should probably have been architected like a web torrent extension to begin, with so this change would bring that closer.

Cool idea. Let me know when you release Web Underground and I'll help spread the word.

btimby commented 3 years ago

@chr15m Thanks for the reply! PR will be inbound once I have tested everything. Also, thanks for the effort you put into Bugout, it is a cool application, I love the RPC interface WITH CALLBACKS! I have never seen RPC with callbacks before, that is slick.

btimby commented 3 years ago

It took me a while to get everything lined up, but I made a PR including my changes to Bugout. I am happy to make further modifications if there is anything you would like to see me do.

chr15m commented 3 years ago

Fixed by #39.