当前位置:网站首页>Jenkins remote publishing products

Jenkins remote publishing products

2022-06-24 11:17:00 Chen Bucheng I

One . brief introduction

WEB Services rarely Jenkins The server is on the same machine , Therefore, you need to package the constructed products , Distribute to remote server for deployment .

Two . Realization

The plugin name :Publish over SSH effect : Used to compile and pass ssh Publish to remote server plug-in

Reflect in the system settings The following appears on the last side , Passphrase An output password , The following machines use the following passwords Click the add button , Installation is as shown in the figure name ,ip, Login account , Which directory appears after login , If you have any 2 The password of each machine is different. Click advanced to add

Click add post build operation , Add a new one Publish over SSH

SSH Server part Name Is the name of the published host , It should correspond to the configuration management options

Source files Select the packaged file , Here for book.tar.gz, Because it is under the working directory ,/var/lib/jenkins/workspace/jenkins Of job name /, If it is somewhere else to write the absolute path

Remove prefix: Remove Directory ( Only... Can be specified Source files In the directory ), It means to remove the prefix of the absolute path , Only move the back book.tar.gz

Remote directory Choose which directory to send to , This is relative to the default directory set in the configuration management selection .( Default /root)

Exec command yes shell Script , Generally, the remote transmission is completed , To start

原网站

版权声明
本文为[Chen Bucheng I]所创,转载请带上原文链接,感谢
https://yzsam.com/2021/06/20210604151112371S.html