简体   繁体   English

SSH 从 windows Jenkins 从属到 ZEDC9F0A5A5D57797BF68E37364743831

[英]SSH from windows Jenkins slave to Linux

I have a windows jenkins slave.From this slave i want to SSH in linux.我有一个 windows jenkins 从站。我想从这个从站到 ZE206A54E976090CCE50CC876 中的 SSH

Below i have given in Jenkinsfile下面我在 Jenkinsfile 中给出

  bat 'ssh -p 22 -pw Qwerty@118 pxx1g9x@1x.1xx.13x.3x'

Here,pxx1g9x is the user and Qwerty@118 is the password for this user.1x.1xx.13x.3x is Ip of linux machine.这里,pxx1g9x是用户,Qwerty@118是这个用户的密码。1x.1xx.13x.3x是linux机器的Ip。

But this is giveing me below error但这给了我以下错误

   ssh: Could not resolve hostname 118: No such host is known. 

I'm not sure whether you can directly pass the password as an argument in ssh, However, you might want to try adding the public key of the slave to the authorized hosts on the linux system.我不确定您是否可以直接将密码作为ssh中的参数传递,但是您可能想尝试将slave的公钥添加到linux系统上的授权主机。

You can see how it is done here.你可以在这里看到它是如何完成的。 https://www.tecmint.com/ssh-passwordless-login-using-ssh-keygen-in-5-easy-steps/ https://www.tecmint.com/ssh-passwordless-login-using-ssh-keygen-in-5-easy-steps/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM