mirror of
https://github.com/house-of-vanity/rexec.git
synced 2025-08-21 23:27:15 +00:00
Update README.md
This commit is contained in:
79
README.md
79
README.md
@@ -5,50 +5,53 @@ Parallel SSH executor in Rust. Read hosts from `known_hosts`
|
|||||||
|
|
||||||
```
|
```
|
||||||
[ab@test debug]$ ./rexec -k admin-gce-sc.* --help
|
[ab@test debug]$ ./rexec -k admin-gce-sc.* --help
|
||||||
Usage: rexec [OPTIONS] --kh <KNOWN_HOSTS> --command <COMMAND>
|
Parallel SSH executor in Rust
|
||||||
|
|
||||||
|
Usage: rexec [OPTIONS] --expression <EXPRESSION> --command <COMMAND>
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
-u, --username <USERNAME> [default: ab]
|
-u, --username <USERNAME> [default: ab]
|
||||||
-k, --kh <KNOWN_HOSTS> Use known_hosts to build servers list
|
-k, --known-hosts Use known_hosts to build servers list
|
||||||
-c, --command <COMMAND> Command to execute on servers
|
-e, --expression <EXPRESSION> Expression to build server list
|
||||||
--code Show exit code ONLY
|
-c, --command <COMMAND> Command to execute on servers
|
||||||
--noconfirm Don't ask for confirmation
|
--code Show exit code ONLY
|
||||||
-p, --parallel <PARALLEL> [default: 100]
|
-f, --noconfirm Don't ask for confirmation
|
||||||
-h, --help Print help
|
-p, --parallel <PARALLEL> [default: 100]
|
||||||
-V, --version Print version
|
-h, --help Print help
|
||||||
|
-V, --version Print version
|
||||||
|
|
||||||
[ab@test debug]$ ./rexec -k admin-gce-sc.* -c uptime -u ab
|
|
||||||
|
[ab@test debug]$ ./rexec -u ab -k -c uptime -e admin.* -f
|
||||||
[INFO ] Matched hosts:
|
[INFO ] Matched hosts:
|
||||||
[INFO ] admin-gce-sc-1.lca-prod.** [35.211.27.195]
|
[INFO ] admin-gce-sc-1.lca-prod.** [35.211.27.195]
|
||||||
[INFO ] admin-gce-sc-1.mmk-prod.** [35.211.79.202]
|
[INFO ] admin-gce-sc-1.mmk-prod.** [35.211.79.202]
|
||||||
[ERROR] admin-gce-sc-1.led-prod.** couldn't ve resolved.
|
[ERROR] admin-gce-sc-1.led-prod.** couldn't be resolved.
|
||||||
[INFO ] admin-gce-sc-1.msq-dev.** [35.211.0.24]
|
[INFO ] admin-gce-sc-1.msq-dev.** [35.211.0.24]
|
||||||
[ERROR] admin-gce-sc-1.hui-dev.** couldn't ve resolved.
|
[ERROR] admin-gce-sc-1.hui-dev.** couldn't be resolved.
|
||||||
Continue on following 3 servers? yes
|
|
||||||
[INFO ]
|
|
||||||
|
|
||||||
[INFO ] Run command on 3 servers.
|
[INFO ] Run command on 3 servers.
|
||||||
[INFO ]
|
|
||||||
|
|
||||||
[INFO ] admin-gce-sc-1.mmk-prod.**
|
[INFO ] admin.gnb-prod.**
|
||||||
[INFO ] Code 0
|
Code 0
|
||||||
[INFO ] STDOUT:
|
STDOUT:
|
||||||
10:20:02 up 284 days, 23:04, 0 users, load average: 0.00, 0.08, 0.16
|
23:31:21 up 294 days, 14:14, 0 users, load average: 0.53, 0.64, 0.52
|
||||||
|
|
||||||
[INFO ] STDERR:
|
STDERR:
|
||||||
|
|
||||||
[INFO ] admin-gce-sc-1.msq-dev.**
|
[INFO ] admin.abe-prod.**
|
||||||
[INFO ] Code 0
|
Code 0
|
||||||
[INFO ] STDOUT:
|
STDOUT:
|
||||||
10:20:03 up 186 days, 23:52, 1 user, load average: 0.12, 0.12, 0.16
|
23:31:22 up 154 days, 9:24, 0 users, load average: 0.31, 0.25, 0.18
|
||||||
|
|
||||||
[INFO ] STDERR:
|
STDERR:
|
||||||
|
|
||||||
[INFO ] admin-gce-sc-1.lca-prod.**
|
[INFO ] admin-gce-be-1.toy-prod.**
|
||||||
[INFO ] Code 0
|
Code 0
|
||||||
[INFO ] STDOUT:
|
STDOUT:
|
||||||
10:20:03 up 292 days, 8:35, 0 users, load average: 0.57, 0.49, 0.47
|
23:31:22 up 98 days, 6:20, 0 users, load average: 0.88, 0.74, 0.80
|
||||||
|
|
||||||
[INFO ] STDERR:
|
STDERR:
|
||||||
|
no server running on /tmp/tmux-1019/default
|
||||||
|
open terminal failed: not a terminal
|
||||||
```
|
```
|
||||||
|
Reference in New Issue
Block a user