Maven Wagon SCP is not able to establish a connection

后端 未结 4 1859
自闭症患者
自闭症患者 2020-12-17 03:14

I am trying to copy resources to another location. I am using maven wagon-ssh plugin to do this. It works fine locally, I am having issues when using Hudson/Jenkins.

4条回答
  •  执念已碎
    2020-12-17 03:37

    maven apparently requires a ssh-rsa entry in the known_hosts file for the jenkins user. You can add the ssh-rsa entry to the file by issuing:

    ssh-keyscan -t rsa YOUR_REMOTE_HOSTNAME >> ~jenkins/.ssh/known_hosts
    

    [[ Added from another answer to make this one definitive. ]]

    Instead, you might be able to add the following to the ~jenkins/.ssh/config. See: How to Avoid Maven builds stall on ssh host authenticity problem?

    StrictHostKeyChecking no
    

提交回复
热议问题