jenkins使用gitlab自动化部署

"Build when a change is pushed to GitLab."

Posted by Jht on September 24, 2016

Build when a change is pushed to GitLab

gitlabpush以后自动触发jenkins job进行build

插件

  • Gitlab Hook Plugin
  • GitLab Plugin

配置

设置SCM

  • new item
  • Source Code Management中选定git
  • 配置git

设置Triggers

img

设置Webhooks

img

提交代码

Push代码,job就能自动运行。