378 发表于 2018-5-27 10:33:32

gitlab+jenkins+maven+docker持续集成(四)——Extended E


  

  构建后进行邮件通知,这里我们用Extended E-mail Notification
  系统管理-->Extended E-mail Notification
  


  

  在这里subject、content为defalut 模板,我们暂不做配置,我这里按项目进行配置

  Extended E-mail Notification 邮件模板见下:
  

  Content Type: HTML(text/html)
  

  Default Subject
构建通知:$PROJECT_NAME - Build # $BUILD_NUMBER - $BUILD_STATUS!  Default Content
<b style="font-size:12px">(<span style="color:red">本邮件是程序自动下发的,请勿回复</span>)<br></b><hr>
<b style="font-size: 12px;">项目名称:$PROJECT_NAME<br></b><hr>
<b style="font-size: 12px;">构建编号:$BUILD_NUMBER<br></b><hr>
<b style="font-size: 12px;">GIT版本号:${GIT_REVISION}<br></b><hr>
<b style="font-size: 12px;" >构建状态:<span style="color:red">$BUILD_STATUS</span><br></b><hr>
<b style="font-size: 12px;">触发原因:${CAUSE}<br></b><hr>
<b style="font-size: 12px;">构建日志地址:<a href="${BUILD_URL}console">${BUILD_URL}console</a><br></b><hr>
<b style="font-size: 12px;">构建地址:<a href="$BUILD_URL">$BUILD_URL</a><br></b><hr>
<b style="font-size: 12px;">变更集:${JELLY_SCRIPT,template="html"}<br></b><hr>  

  配置后一定要选择Triggers,

  

  这样配置后构建成功与失败都会收到邮件
  


  

  

  

  

  

  

  

  
页: [1]
查看完整版本: gitlab+jenkins+maven+docker持续集成(四)——Extended E