|
1 |
| -# Topoviewer |
2 |
| - |
3 | 1 | ## Overview
|
4 |
| -Yo, listen up! This mind-blowing project is all about hooking you up with the dopest network visualization tool out there. We're talking about taking your topology data and turning it into a sick cytoscape graph model that you can peep using https://js.cytoscape.org. It's like having a virtual eye candy for your network! |
5 | 2 |
|
6 |
| -Now, let's break it down into two rad sections: |
| 3 | +[`topoViewer`] is a network visualization tool that converts topology data into a Cytoscape graph model, allowing you to visualize your network using [Cytoscape.js](https://js.cytoscape.org). |
| 4 | + |
| 5 | +The project is divided into two main components: |
| 6 | + |
| 7 | +- **TopoEngine**: Converts topology data (currently supports Container Lab) into a Cytoscape graph model. This component handles the core logic for processing and visualizing network topologies, including parsing topology files and generating visual representations. |
| 8 | + |
| 9 | +- **CloudshellWrapper**: A wrapper for [cloudshell](https://github.com/zephinzer/cloudshell) that provides an Xterm.js frontend connected to a Go backend, allowing you to access your shell via a browser. If CloudshellWrapper is running on the same host as Containerlab, it can also access the nodes of Containerlab through the browser. |
| 10 | + |
| 11 | +> **Note**: Exposing your shell via a browser can be risky. Use at your own risk. |
| 12 | +
|
| 13 | +The codebase is organized into several folders with the prefix `go_`, each serving a specific purpose: |
| 14 | + |
| 15 | +- **go_cloudshellwrapper**: Contains the main logic for running [`topoViewer`]. Key files include: |
| 16 | + - `cmd/main.go`: The entry point for running [`topoViewer`]. |
| 17 | + - `cmdClab.go`: Handles CLAB-specific commands. |
| 18 | + - `cmdNsp.go`: Handles NSP-specific commands. |
| 19 | + - `utils.go`: Contains utility functions such as `createMemoryLog` and `createRequestLog`. |
| 20 | + - Additionally, the `clabHandlers` directory contains handlers specific to Containerlab operations. |
7 | 21 |
|
8 |
| -TopoEngine: This bad boy is all about converting your topology data (right now it's Container Lab) into a sick cytoscape graph model. Once translated, you can visualize that bad boy and watch your network come to life. |
| 22 | +- **go_topoengine**: Contains the core logic for processing and visualizing network topologies. This includes parsing topology files and generating visual representations. |
9 | 23 |
|
10 |
| -CloudshellWrapper: Here's the deal, we've got a wicked wrapper for https://github.com/zephinzer/cloudshell. It's like having your own personal Xterm.js frontend that connects to a Go backend and gives you a shell right in your browser. Yeah, you heard it right, access your shell using your browser. It's like having a virtual command center at your fingertips. And guess what? If you're running CloudshellWrapper on the same host as containerlab, you can even access the nodes of containerlab through your browser. How cool is that? |
| 24 | +- **go_xtermjs**: Integrates `xterm.js` for terminal emulation within the [`topoViewer`]interface. This allows users to interact with the terminal directly from the web interface. |
11 | 25 |
|
12 |
| -But hey, keep in mind, exposing your shell via a browser can be risky business. We're just putting it out there, so if you decide to dive in, do it at your own risk. Stay rad, my friend! |
| 26 | +- **go_tools**: Contains various utility functions and tools used by [`topoViewer`]. |
13 | 27 |
|
14 | 28 |
|
15 | 29 | ## Quickstart
|
|
0 commit comments