前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >Jenkins 自动化部署 持续集成

Jenkins 自动化部署 持续集成

作者头像
一个会写诗的程序员
发布2018-08-17 14:09:06
4270
发布2018-08-17 14:09:06
举报

螢幕快照 2017-11-18 22.56.06.png

Source files

代码语言:javascript
复制
build/libs/cms-0.0.1-SNAPSHOT.jar

Help for feature: Source files Files to upload to a server.

The string is a comma separated list of includes for an Ant fileset eg. '*/.jar' (see Patterns in the Ant manual). The base directory for this fileset is the workspace.

Remote directory

代码语言:javascript
复制
/usr/local/cms

Help for feature: Remote directory Optional destination folder.

This folder will be below the one in the global configuration, if present. The folder will be created if does not exist.

Exec command

代码语言:javascript
复制
set pid = $(ps -ef|grep java|grep kotlin|awk '{print $2}')
if (test $pid)
then
kill -9 $pid
fi
cd /usr/local/cms
nohup java -jar cms-0.0.1-SNAPSHOT.jar &

A command to execute on the remote server

This command will be executed on the remote server after any files are transferred. The SSH Transfer Set must include either a Source Files pattern, an Exec command, or both. If both are present, the files are transferred before the command is executed. If you want to Exec before the files are transferred, use 2 Transfer Sets and move the Exec command before the Transfer set that includes a Source files pattern.


image.png

image.png

代码语言:javascript
复制
fuser -k 8010/tcp
cd /usr/local/cms
nohup java -jar cms-0.0.1-SNAPSHOT.jar &

image.png

本文参与 腾讯云自媒体分享计划,分享自作者个人站点/博客。
原始发表:2017.11.18 ,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体分享计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档