Execute Shell script from workspace on remote machine after build successful (Jenkins)

二次信任 提交于 2019-12-03 06:33:38

As part of Publish Over SSH Plugin, you can execute a script after the files had been copied over.

  • Under Post-build Actions
  • Add Send build artifacts over SSH
  • Select a preconfigured server (done in global configuration)
  • Select files to copy from workspace
  • Enter Exec command
    1. If one of the files you copy is your shell script, you can enter it here as an "exec command"
Abhijeet Kamble

To solve my query i used Jenkins SSH Plugin. This provides a configuration tab where i can add multiple hosts and after that used them in my job level configuration.

Link to Plugin

you get privilege to execute shell script on remote host as pre-build step or post build step.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!