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

Interface for viewing watchtowers #228

Open
orbitalturtle opened this issue Jul 7, 2023 · 7 comments
Open

Interface for viewing watchtowers #228

orbitalturtle opened this issue Jul 7, 2023 · 7 comments

Comments

@orbitalturtle
Copy link
Contributor

This is an idea I've had for a while. Not sure if this is necessarily the best place to put this, since it isn't teos-specific, but figured I'd jot it down here for discussion or to see if anyone is interested.

It'd be really nice to have a simple website where watchtowers are listed. For now, there are lists like this, which are very helpful. #158 But it might be nice to have an easy website to click to, and to be able to see other information about each watchtower.

One very important factor that comes to mind is having a running idea of whether the tower is actually up or down. The runner of this website could set up a cron job that pings all the towers every so often (using the ping api endpoint if that seems sufficient?) to make sure they're still up and the interface could show each tower's current status. Along these lines, it could track what percentage of the time the tower is actually running. It could show estimates of how often towers go down. This information would be quite nice for users to have: If a tower is up 99% of the time, seems better to connect to that than one that's only up 50% of the time.

Perhaps anyone could post their tower to this website. Maybe they'd just have to authenticate with an LSAT (or something) to prevent spam.

Side note: This could definitely include lnd watchtowers as well! Not sure if there are any other implementations.

@sr-gi
Copy link
Member

sr-gi commented Jul 11, 2023

I think this is a great idea. I hope someone with good front-end skills picks it up, otherwise, I may suggest it as a SoB project for the next edition.

@lujakob
Copy link

lujakob commented Aug 17, 2023

@orbitalturtle I have been studying the https://doc.rust-lang.org/stable/book for the last couple of days and need some pet project. I will give this a try. I will build the backend/API in Rust and frontend in React.

@lujakob
Copy link

lujakob commented Aug 17, 2023

@sr-gi do you know how can I ping one of those watchtowers, e.g. yours in #158 (comment) - could you post me the curl request please?

@mariocynicys
Copy link
Collaborator

mariocynicys commented Aug 17, 2023

@lujakob curl -i towerurl.tld:9814/ping

Also for tor, you can use this: curl -is --socks5-hostname 127.0.0.1:9050 toweronionaddress.onion:9814/ping
assuming you have a tor proxy daemon running on localhost:9050

@lujakob
Copy link

lujakob commented Aug 17, 2023

@lujakob curl -i towerurl.tld:9814/ping

Also for tor, you can use this: curl -is --socks5-hostname 127.0.0.1:9050 toweronionaddress.onion:9814/ping assuming you have a tor proxy daemon running on localhost:9050

I tried curl -i 03b0a47228c8b36477002d745cf578a4db2b7c2ba2e2aee2c65419053e4375a1dd@satseye.slicksparks.ky:9814/ping and get

HTTP/1.1 405 Method Not Allowed
content-type: text/plain; charset=utf-8
content-length: 23
date: Thu, 17 Aug 2023 15:27:44 GMT

HTTP method not allowed%

@mariocynicys
Copy link
Collaborator

I tried curl -i 03b0a47228c8b36477002d745cf578a4db2b7c2ba2e2aee2c65419053e4375a1dd@satseye.slicksparks.ky:9814/ping and get

You don't need the tower pubkey included to ping it. Also curl wouldn't interpret it the as intended anyways.

The tower you are pinging probably doesn't have the /ping endpoint yet (because it was introduced recently in #200)

This tower curl -i teos.mariocynicys.cf:9814/ping should return 200 OK since it applies the /ping patch.

@orbitalturtle
Copy link
Contributor Author

@lujakob hellz yes

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

No branches or pull requests

4 participants