Skip to content
/ gopssh Public

Utility for execute command at remote servers by ssh

License

Notifications You must be signed in to change notification settings

unixzen/gopssh

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gopssh

Utility for execute command at remote servers by ssh

Usage

  1. Clone repo gopssh
git clone https://github.com/unixzen/gopssh.git
  1. Build binary
cd ./gopssh
go build gopssh.go
  1. Create config file - config.yaml

Example config file:

---

ssh_key_path: "/home/user/.ssh/id_rsa"
ssh_user: "root"
ssh_password: "testpassword"
ssh_port: "22"
method: "key"
command: "uptime"
passphrase: "testphrase"
hosts: 
  - host1
  - host2
  - host3
  1. Start gopssh
./gopssh

Example output:

user@localmachine:~/notes/repo/gopssh $ ./gopssh
host1
 14:10:38 up 13 days,  1:52,  1 user,  load average: 0.00, 0.00, 0.00

About

Utility for execute command at remote servers by ssh

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages