Skip to content

Commit

Permalink
Rewrite README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
f0o committed Sep 7, 2024
1 parent a516f7b commit 322c29d
Showing 1 changed file with 14 additions and 15 deletions.
29 changes: 14 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,31 @@
# looking-glass
Just another looking glass software because all existing ones are either dead or ancient
Just another looking glass software because all existing ones are either dead or ancient.

# Demo
[AS203038](https://lg.as203038.net/) runs this as a daily driver.
[AS203038](https://lg.as203038.net/) uses this as a daily driver.

# Tech Stack
The foundation is built on Golang and gRPC (ConnectRPC to be precise). This Golang codebase is responsible for any and all interactions with the routers through SSH, in future plans an embedded goBGPD is planned.
The foundation is built on Golang and gRPC (specifically ConnectRPC). This Golang codebase handles all interactions with the routers through SSH. Future plans include incorporating an embedded goBGPD.

The WebUI is built using SvelteKit and served as static files embedded in the final Golang binary, all configurations for the UI are injected in runtime by autogenerating the env.js.
The WebUI is built using SvelteKit and served as static files embedded in the final Golang binary. All UI configurations are injected at runtime by auto-generating the `env.js` file.

WebUI and Golang communicate using gRPC-Web through ConnectRPC's SDKs with eachother.
The WebUI and Golang communicate using gRPC-Web through ConnectRPC's SDKs.

In future there will be a generic CLI client that can connect to arbitrary instances of this looking-glass allowing you to query multiple instances at once. Assuming anyone actually will run this other than us.
There is also a generic gRPC client available for direct interaction with the backend, in case you prefer not to use the WebUI. It is released as the lg-cli artifact in the releases. If you want, you can add your LG instance to the [public_index.yaml](https://github.com/AS203038/looking-glass/blob/main/public_index.yaml) file and submit a PR.

# Configuration
All config is done in a single YAML. It's probably not perfect but it works well enough for now.
All configuration is done in a single YAML file. It may not be perfect, but it works well enough for now.

Example config is supplied with all release builds but can also be found [Here](https://github.com/r0cket-net/looking-glass/blob/main/example.config.yaml).
An example config is included with all release builds and can also be found [here](https://github.com/AS203038/looking-glass/blob/main/example.config.yaml).

# Scalability
The server is stateless. It will work well with multiple replicas and loadbalancing schemes as long as the loadbalancer can serve gRPC traffic (HTTP/2).
The server is stateless and can work well with multiple replicas and load-balancing schemes, as long as the load balancer can handle gRPC traffic (HTTP/2).

Router Listing is paginated and the UI will switch to a expandable list format grouped by locations when too many routers are supplied (>4 decided by dice roll).
However other outputs (such as BGP routes, traceroute, ...) is not yet paginated as it would break statelessnes of the backends.
You are able to request full bgp tables through the UI, Chrome will crash and Firefox will become a slideshow but the backend will happily serve it without any issues.
Router listing is paginated, and the UI switches to an expandable list format grouped by locations when there are too many routers (>4, determined by a dice roll). Large outputs, such as BGP routes and traceroute, are now paginated to prevent browser crashes. You can request full BGP tables through the UI without any issues (except for Firefox on Windows arm64).

# Logging
HTTP Requests are logged using common Apache Access Log Format (without timestamp)
HTTP requests are logged using the common Apache Access Log Format (without timestamp).

Optionally, you can enable Sentry logging and tracing, which will be applied to both the frontend and backend.

# Contributions
More than welcome! We 100% would love more router models - if you do not want to write the code yourself you can also give us ReadOnly access to your router/s and we write the models.
Contributions are more than welcome! We would love to have more router models. If you don't want to write the code yourself, you can also give us read-only access to your router(s), and we will write the models.

0 comments on commit 322c29d

Please sign in to comment.