Add mdBook documentation with Ghostty-style sidebar
This commit is contained in:
@@ -0,0 +1,72 @@
|
||||
# Monitor Multiple Hosts with Zellij
|
||||
|
||||
Use Zellij to monitor multiple socktop instances in a single terminal.
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
cargo install zellij
|
||||
```
|
||||
|
||||
## Example Layout
|
||||
|
||||
Create `socktop-layout.kdl`:
|
||||
|
||||
```kdl
|
||||
layout {
|
||||
pane split_direction="vertical" {
|
||||
pane command="socktop" {
|
||||
args "-P" "rpi-master"
|
||||
}
|
||||
pane command="socktop" {
|
||||
args "-P" "rpi-worker-1"
|
||||
}
|
||||
}
|
||||
pane split_direction="vertical" {
|
||||
pane command="socktop" {
|
||||
args "-P" "rpi-worker-2"
|
||||
}
|
||||
pane command="socktop" {
|
||||
args "-P" "rpi-worker-3"
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
Run it:
|
||||
|
||||
```bash
|
||||
zellij --layout socktop-layout.kdl
|
||||
```
|
||||
|
||||
## More Info
|
||||
|
||||
For detailed Zellij documentation, see [Zellij](https://zellij.dev/).
|
||||
|
||||
Create `~/.config/zellij/layouts/socktop-monitoring.kdl`:
|
||||
|
||||
```kdl
|
||||
layout {
|
||||
pane_template name="socktop_pane" {
|
||||
command "socktop"
|
||||
args "-P" "{profile}"
|
||||
}
|
||||
|
||||
pane split_direction="vertical" {
|
||||
pane split_direction="horizontal" {
|
||||
socktop_pane profile="production-web"
|
||||
socktop_pane profile="production-db"
|
||||
}
|
||||
pane split_direction="horizontal" {
|
||||
socktop_pane profile="staging-web"
|
||||
socktop_pane profile="staging-db"
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Use the Layout
|
||||
|
||||
```bash
|
||||
zellij --layout socktop-monitoring
|
||||
```
|
||||
Reference in New Issue
Block a user