How does the Gerrit- trigger plugin in Jenkins works?

僤鯓⒐⒋嵵緔 提交于 2019-12-03 06:11:32

问题


I am trying to understand how does the gerrit-trigger in Jenkins works in details? Also, how is the test for the triggered cose is being invoked ?

Thanks,


回答1:


The gerrit trigger works like this:

  1. It connects to the gerrit server using ssh and uses the gerrit stream-events command

  2. It then watches this stream as the data comes in

  3. It will try to match the events to triggers that have defined in your projects

Potential pit-falls:

  1. Jenkins user has improper ssh credentials

  2. Jenkins user does not have the stream-events rights

How to check:

  1. Login as jenkins user

  2. ssh -p 29418 jenkins@your.domain.com gerrit stream-events

  3. Push a commit to the server and you should see things on your stream

Problems:

  1. ssh connection failed? setup you ssh key pair

  2. No streaming right? Go to the All-Projects->Access and under Global Capabilities add Stream Events to the Non-Interactive Users group



来源:https://stackoverflow.com/questions/16106898/how-does-the-gerrit-trigger-plugin-in-jenkins-works

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