1 Star 0 Fork 133

shengzhe8688 / K8tools

forked from bxqtee / K8tools 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
sshcmd.py 309 Bytes
一键复制 编辑 原始数据 按行查看 历史
k8gege 提交于 2019-06-08 18:34 . Add files via upload
import paramiko
import sys
print("sshcmd 1.0")
print("by k8gege")
ssh = paramiko.SSHClient()
ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
ssh.connect(sys.argv[1], sys.argv[2], sys.argv[3], sys.argv[4])
stdin, stdout, stderr = ssh.exec_command(sys.argv[5])
print stdout.read()
ssh.close()
PowerShell
1
https://gitee.com/shengzhe8688/K8tools.git
git@gitee.com:shengzhe8688/K8tools.git
shengzhe8688
K8tools
K8tools
master

搜索帮助