Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/whme/csshw
Cluster SSH tool for Windows inspired by csshX
https://github.com/whme/csshw
ssh windows
Last synced: 2 months ago
JSON representation
Cluster SSH tool for Windows inspired by csshX
- Host: GitHub
- URL: https://github.com/whme/csshw
- Owner: whme
- License: apache-2.0
- Created: 2021-09-10T22:34:01.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-05-31T14:06:42.000Z (7 months ago)
- Last Synced: 2024-08-01T10:17:49.245Z (5 months ago)
- Topics: ssh, windows
- Language: Rust
- Homepage:
- Size: 9.65 MB
- Stars: 5
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
- awesome - whme/csshw - Cluster SSH tool for Windows inspired by csshX (windows)
README
# csshW
_Cluster SSH tool for Windows inspired by [csshX](https://github.com/brockgr/csshx)_![csshw demo](https://github.com/whme/csshw/blob/21d218db0d2c0366d413dad8379bdc9544f75bf8/demo/csshw.gif)[^1][^2]
[![License](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
## Pre-requisites
- Any SSH client (Windows 10 and Windows 11 already include a built-in SSH server and client - [docs](https://learn.microsoft.com/en-us/windows/terminal/tutorials/ssh))
- ``Default terminal application`` is set to ``Windows Console Host`` in the windows Terminal Startup Settings (Windows 11 only)## Overview
csshW will launch 1 daemon and N client windows (with N being the number of hosts to SSH onto).
Key-strokes performed while having the daemon console focussed will be sent to all clients simoultaneously and be replayed by them.
Focussing a client will cause any key-strokes to be sent to this client only.## Download/Installation
csshW is a portable application and is not installed.
To download the csshW application refer to the [Releases 📦](https://github.com/whme/csshw/releases) page.## Usage
```cmd
csshw.exe --help
Cluster SSH tool for Windows inspired by csshXUSAGE:
csshw.exe [OPTIONS] [HOSTS]... [SUBCOMMAND]ARGS:
... Hosts to connect toOPTIONS:
-d, --debug Enable extensive logging
-h, --help Print help information
-u, --username Username used to connect to the hosts
-V, --version Print version informationSUBCOMMANDS:
client
daemon
help Print this message or the help of the given subcommand(s)
```
Example:
`csshw.exe -u root hosta.dev hostb.dev hostc.dev`We recommend using the [ssh_config](https://linux.die.net/man/5/ssh_config) for any configurations like default username etc.
### Configuration
`csshw-config.toml` contains all relevant configurations and is located in the same directory as the executable.
It is automatically created with default values if not present.#### `clusters`
An array of clusters that can be used to alias a set of host names to a specific tag:
```toml
clusters = [
{ name = "dev", hosts = ["hosta.dev", "[email protected]", "hostc.dev"] }
]
```
Clusters may be nested, but be aware of recursive clusters which are not checked for.#### `client`
A collection containing client relevant configuration
``` toml
[client]
ssh_config_path = 'C:\Users\demo_user\.ssh\config'
program = 'ssh'
arguments = [
'-XY',
'{{USERNAME_AT_HOST}}',
]
username_host_placeholder = '{{USERNAME_AT_HOST}}'
```##### `ssh_config_path`
The full qualified path where your ssh configuration can be found.##### `program`
Which executable will be used to establish ssh connections.##### `arguments`
Additional arguments specified to the chosen program.##### `username_host_placeholder`
Placeholder string that indicates where the `username@host` string should be inserted in the program arguments.#### `daemon`
A collection containing daemon relevant configuration
``` toml
[daemon]
height = 200
aspect_ratio_adjustement = -1.0
console_color = 207
```##### `height`
The height of the daemon console.##### `aspect_ratio_adjustment`
Configures whether the available screen space should rather be used horizontally or vertically.##### `console_color`
Configures background and foreground colors used by the daemon console.
Available are all standard windows color combinations ([windows docs](https://learn.microsoft.com/en-us/windows/console/console-screen-buffers#character-attributes)):
```
FOREGROUND_BLUE: 1
FOREGROUND_GREEN: 2
FOREGROUND_RED: 4
FOREGROUND_INTENSITY: 8
BACKGROUND_BLUE: 16
BACKGROUND_GREEN: 32
BACKGROUND_RED: 64
BACKGROUND_INTENSITY: 128
```
e.g. white font on red background: 8+4+2+1+64+128 = `207`## Contributing
csshW uses pre-commit githooks to enforce good code style.
Install them via ``git config --local core.hooksPath .githooks/``.[^1]: The searchbar used to launch csshw in the demo clip is [keypirinha](https://keypirinha.com/).
[^2]: The tool to show key presses in the demo clip is [carnac the magnificent](http://carnackeys.com/).