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

dat / ready-to-use #3

Open
callil opened this issue Apr 4, 2018 · 29 comments
Open

dat / ready-to-use #3

callil opened this issue Apr 4, 2018 · 29 comments
Labels

Comments

@callil
Copy link
Contributor

callil commented Apr 4, 2018

Initial thoughts on how this tool might develop

dat-ready-to-use would be a no-config rpi setup that would drastically simplify the UX of being a part of the dat network.

For instance:

  1. plug in pi
  2. navigate to dat.local on any computer
  3. add dat url to configure and turn on mirroring services (content and peers)

Some sort of front-end gets you the ability to add custom urls - fine tune peering settings etc.

This tool could be especially useful when connected to mesh networks or small local networks to instantly peer and support access to content and services within the network.

It can also act as a proxy for a regular users beaker browser pinning habits. Maybe beaker can build in a small utility to turn on peer mirroring so this node would automatically add any pinned sites in beaker to the list.

It may also be interesting to eventually think of this tool as less of a mirroring tool, but actually the permanent peer through which services like social networks on dat run. With multi-writer people would get the ability to edit permissions and their own information from any computer provided they can authenticate the private key (like google authenticator)

@callil
Copy link
Contributor Author

callil commented Apr 5, 2018

v01 add

a figma napkin sketch to get this idea out there.
the site is just a dat with a gui for entering configs - behind the scenes there would need to be a small node app restarting the swarms and speaking to dathttpd when things changed along with some simple logging.

There are some other interesting ideas that popped up when I was thinking about this. Communities could seed dat sneakernets like this proposal https://github.com/m-onz/hyperdat-paper that are one click ways of joining a mass swarm for your neighborhood or learning-group

One route might be to essentially fork hashbase - or make a similar service with a focus on self hosting and management.

@callil callil added the idea label Apr 5, 2018
@neauoire
Copy link
Collaborator

neauoire commented Apr 5, 2018

I have a rasp pi image which does something very similar.
It automatically streams all sites found in /pi/beaker and makes them available to all connected devices. I would be happy to help with this project.

@callil
Copy link
Contributor Author

callil commented Apr 5, 2018

@neauoire this would be a big help. Does your tool have a front end for adding sites yet?

@neauoire
Copy link
Collaborator

neauoire commented Apr 5, 2018

No, as I think that would be more cumbersome than not. Managing RPi through SSH seems like the way to do it. I could build a blessed based front-end with instructions, but it works so well headlessly, and is so simple that it might not be necessary.

To monitor traffic I use the dat tools to see the number of peers, but could be added to the blessed front-end, made to look similar to your preview image up on top here :) Let me give this a try.

@louiscenter
Copy link
Collaborator

I'm seeing the value in building a GUI that's accessible via dat.local in the browser. ssh, blessed, and /pi/beaker won't mean a lot to those who don't come from a background in writing code, and it would be nice to aim projects like this at a broad audience.

if @neauoire is happy to provide his code, I'd be happy writing a choo front-end for it that writes and updates things inside of pi/beaker.

@louiscenter
Copy link
Collaborator

likewise, this could tie into the hypercored related front. a choo app for hypercored would be fire.

@neauoire
Copy link
Collaborator

neauoire commented Apr 5, 2018

That sounds good, you can control the backend tools easily, as everything I'm doing for this is npm based, and enabling/disabling sites would be a text file.

So, just to make sure I'm understanding correctly. The end game is:

  • To distribute an .img file that people can burn on their SD card.(I can make, it will be Raspbian)
  • That automatically starts to serve content upon being powered.(That's what I have already)
  • Reachable to through dat.local (the url of the front-end control panel)
  • With control tools that allows to manage dat sites and content existing on the SD card.(A list of available sites, with enable site / disable site front-end options)
  • For the non-programmerkin.

@urcades
Copy link

urcades commented Apr 5, 2018

I'm seeing the value in building a GUI that's accessible via dat.local in the browser. ssh, blessed, and /pi/beaker won't mean a lot to those who don't come from a background in writing code, and it would be nice to aim projects like this at a broad audience.

yeah, everything here resonates strongly — something you can literally plug into a wall and browse to on a phone or laptop nearby would be incredible

@louiscenter
Copy link
Collaborator

@edouerd @neauoire @callil if anyone wants to whip up a design, I'll start the choo repo. I could also just start with cal's above?

@urcades
Copy link

urcades commented Apr 5, 2018

yeah, you can def start off with what cal has defined above! in general, a lot of our works are longer-term/form in nature (and will likely evolve over time) but there's nothing stopping us from getting something out there now

@callil
Copy link
Contributor Author

callil commented Apr 5, 2018

I think you can start with the above - it was a super quick sketch though. @louiscenter I can also write the front-end with you.

Here is the working document. I will look at this a bit more seriously tonight and maybe we can work through comments on the figma.

I think we should aim for what @neauoire has outlined above. Can we also add the ability to confiugure custom domain names to the tool the way dathttd does? Also eventually being able to get this on a droplet via docker may be a really valuable step too.

Also, how should we align the pieces of this project? We may want to start a team/project repo to align a bit more so there is a single source and open some of these ideas as single issues. Are you all ok with doing it in newcomputers org?

@neauoire
Copy link
Collaborator

neauoire commented Apr 5, 2018

Assign me a repo and I will use it to assemble the parts for the backend.
I think that providing a linux image with everything installed and ready to be connected to the wall is a better option to the non-programmerkin than having to run a shell script through SSH. So I will focus on that.

@louiscenter
Copy link
Collaborator

@callil spin up any repos within newcomputers and lets give it a go! I'm happy to setup the skeleton for the front-end if you give me a repo to work from

@callil
Copy link
Contributor Author

callil commented Apr 5, 2018

Actually - let's keep this repo for this project I'll move the rest to a guides repo unless someone has major objections.

@louiscenter
Copy link
Collaborator

louiscenter commented Apr 5, 2018

couple more things to clarify:

  • @neauoire, will you be contributing an rpi image which contain the node scripts, or just the node scripts?

  • if the aim of this repo is to build an rpi image, which is made up of a front-end and a back-end, won't we need to build those two out first and get those working on rpi before bundling them all together in a pre-configured rpi image?

@louiscenter
Copy link
Collaborator

my feeling is that there should be a repo for a front-end app, a repo for @neauoire's node scripts, then we can use this repo for the rpi image that wraps all these together.

@neauoire
Copy link
Collaborator

neauoire commented Apr 5, 2018

@neauoire, will you be contributing an rpi image which contain the node scripts, or just the node scripts?

Both

if the aim of this repo is to build an rpi image, which is made up of a front-end and a back-end, won't we need to build those two out first and get those working on rpi before bundling them all together in a pre-configured rpi image?

As of now, I have a RPi image, that automatically serves a control panel(it just says hello, really) upon connection to USB power, the site that it serves is ~/Public/Home which will display a list of all hosted dat sites(@louiscenter's), which are all accessible through http and synched across dat.

screen shot 2018-04-06 at 11 16 28 am

It's missing a few things:

  • the ability to enable/disable the sharing of each particular sites.
  • controls for domain names, which I know nothing about.
  • monitoring of connected peers.
  • a sort of interface to manage all of this.
  • the final image will be called dat.local, blackberry.local is my development device's name.

@jondashkyle
Copy link

yo this sounds awesome! i'm down to contribute some to the design of the interface.

@matamalaortiz
Copy link

wow this is great, happy to contribute to the design as well if an extra hand is needed.

@kodedninja
Copy link

I've made a releasable version of my RPi seeder. It's very primitive and has a very ugly frontend, but it works and it's fairly simple: https://github.com/kodedninja/seeder.

Also, hell yeah, I would like to contribute!

@neauoire
Copy link
Collaborator

neauoire commented Apr 9, 2018

So, I've been trying to tackle this over the weekend and most of the plan is working but I'm having the following issue, if anyone have any insight, I'd love to hear:

Whenever I run a dat server over dat, over night(using forever in this case), when I wake up, the site is inaccessible. I noticed that I could not even SSH in the device in the morning, so I connected in gadget mode to see what was wrong, the dat server was still running, but when trying to ping anything, the internet seemed down. Checking wicd says that there is no more available LAN devices.

I've had the same issue with the Pi Zero W, and the 2B+.

So I've ran a log throughout last night, and what happens is that even tho nobody is trying to connect to the Pi. The memory usage increases and increases, and the device takes increasingly more power and does a sort of kernel panic for a while, then comes back back, breaking the wifi connection stuff.

Anyone managed to server a dat site for more than 6-7 hours?
I'm starting to wonder if maybe I have a failing USB wire.. or some other weird unrelated issue.

@kodedninja
Copy link

@neauoire currently I'm seeding 7 sites with my seeder pi and it was seeding through the night. Everything looks good.

I have a Model B.

@neauoire
Copy link
Collaborator

I got myself a shorter, newer fast charging USB wire.
Putting it to the test tonight.

@neauoire
Copy link
Collaborator

Okay the problem is gone. It was a power issue, I saw someone else having the same problem and a new USB wire seems to have fixed it.

@neauoire
Copy link
Collaborator

Are you monitoring @pfrazee's Homebase?
https://github.com/beakerbrowser/homebase

@cblgh
Copy link

cblgh commented Apr 12, 2018

[chiming in to say that i've been following this closely, and i'd love to be added to new-computers to help contribute :]
👋

@callil
Copy link
Contributor Author

callil commented Apr 12, 2018

@neauoire looks like home base will do most of what we are discussing on the back end. I'm particularly excited by the beaker pinning api it hints at. I wonder what @pfrazee is planning to do for front-end work and I think it's still very worth while to work on getting things closer to plug and play once that lands.

@cblgh yay super excited to have you here - check out https://github.com/new-computers/seeder for the latest applied stuff from this discussion

@m-onz
Copy link

m-onz commented Apr 12, 2018

Please add me new-computers too, I want to be an official contributor. I can dedicate time and effort to this project. I can also test stuff on all the available raspberry Pis and with different network conditions (real and simulated).

@callil
Copy link
Contributor Author

callil commented Apr 12, 2018

@m-onz done - sorry I thought I had already got you in here

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

No branches or pull requests

9 participants