I'm completely stuck with Gerrit Trigger install. I installed Jenkins ver. 1.482 with the Gerrit Trigger (v2.6.0) plugin. I'm not able to configure it.
I installed a test gerrit server (v2.4.2). I have an admin user. I tried to configure Gerrit Trigger to use this access to build patches (this is a test system, I didn't want to bother to add real users).
In Gerrit Trigger options I configured gerrit access. Test connection button says conection is ok. Although I get The connection to Gerrit is not started yet. Check the Gerrit URL in the settings. warning on the top. I also tried to push restart at the bottom.
I've read documentation on both Hudson and Jenkins page of the plugin. I'm still unable to configure the plugin.
Do you have any idea what's wrong?
Probably Click the button to Save after testing, this is common mistake that you forget to save it !! I met this several times
See more explanation in https://wiki.jenkins-ci.org/display/JENKINS/Gerrit+Trigger
Otherwise it is not clear what's your problem since this is a normal case.
Related
I'm trying to use JIRA Trigger Jenkins plugin. I've read maybe all similar issues but can't understand why it doesn't work.
I want to build when an issue status changed. I troubleshooted but it didn't help me. My web hook works I checked it as it shows in documentation, the plugin for Jenkins is installed, firewall checked (I have whitelisted 3 Jira cloud IPs for Jenkins instance on AWS), ssl checks on Jenkins passes. Also I configured logs on Jenkins from Jira, but can't get anything.
In trigger configuration I inserted my Jira user's email (my-email#gmail.com) as user and password. The user has administrator privileges. What else can be wrong? Please any idea.
I am using Jenkins with Perforce. I have downloaded the P4 Plugin, and I have read over the documentation but I am still a bit confused. In my Jenkins project, I have the build trigger set to "Perforce triggered build". I'm assuming that means I need to add a trigger to Perforce that tells Jenkins to run a build, but I have no idea on how to do that.
I have not been able to find any documentation on how to implement a trigger from Perforce to notify Jenkins it needs to run. I can find documentation from Perforce on how to setup basic triggers, but I can not find anything from Jenkins on how to set up the actual connection to trigger builds on Perforce submits.
On the "Changes" tab in Jenkins, I am able to see the what was submitted to Perforce, so I know that Perforce and Jenkins are at least communicating. Initially, I thought that Jenkins would just automatically run the build on a Perforce submit, if I had "Perforce triggered build" checked, but that doesn't seem to be the case.
So my questions are:
Am I correct in assuming that I need to manually create a trigger to be added to Perforce?
If so, does anyone know of any documentation or examples that I can look to as a guide?
Yes, you need to add a trigger to Perforce. It's well documented here.
I was able to see standard Jenkins dashboard (configuration dashboard). Suddenly after a couple of logins, the manage Jenkins option is gone. All that I see is \People
Build History
Credentials
I am not able to spin builds or make changes. How can I make sure that all those options come back. I have tried uninstalling and reinstalling as well. Appreciate your response.
I cant figure out how to setup gerrit trigger plugin.
Manual build start builds current repo correctly. Test gerrit plugin connection is "Success".
Gerrit is configured according to plugin description article: https://wiki.jenkins-ci.org/display/JENKINS/Gerrit+Trigger
Jenkins is 1.635; Gerrit trigger is 2.17.2. Gerrit is v2.11.3
Also tried "Type: plain. Pattern: project1, branches: */base/**" gerrit project settings. didnt work.
Gerrit trigger plugin global config:
Gerrit trigger plugin global config expanded (it has serveradmin user on the picture but i tried user created for jenkins as well):
Job settings:
Probably I'm missing something. Is there a way to figure out what's wrong? Maybe some console commands to figure out if gerrit jenkins user can reach the stream & plugin log?
It seems you need to update Gerrit to the last version and give the good "Access Right" to your Jenkins user.
Follow this set up
I'm trying to configure a local installation of Jenkins to review uploaded changes on Gerrit. So far, I've gotten Jenkins to detect uploaded changes and build them (using Gerrit Trigger). However, while the build concludes successfully on Jenkins, it doesn't post any reviews on Gerrit, even though it is configured to do so. Interestingly, in Gerrit change history, I can see Jenkins having started a build:
Jenkins Patch Set 1: Build Started http://localhost:8080/job/TestProject/70/
but that's it. No results are shown after this, like successful conclusion of the build etc. Since I can see the build started result, I'm assuming I've configured the review settings correctly, but something else is causing a hold up. I've checked in the Gerrit error_log file and it doesn't show any errors. What maybe the issue?
By the way I've been able to verify/review the code as jenkins using the command line.
To make code verification possible, you have to go through the following steps:
Allow label “Verified” on Gerrit server (also see here or here);
Read this and make sure your job configured properly, because you will not build latest changesets instead;
Give access to labels Code-Review and Verified in your Gerrit project for user Jenkins;
I was able to resolve this by adding the 'Verified Label' to the Gerrit Server. The version of Gerrit I used (2.11.3) explicitly asks you to install the Verified Label, and the default option is set at No and as a result I didn't install it. I simply reinstalled my Gerrit, this time choosing Yes on Install Verified Label. If you're facing this issue, simply reinstall your Gerrit. If re-installation is not an option, read this:
http://blog.bruin.sg/2013/04/how-to-edit-the-project-config-for-all-projects-in-gerrit/
Some basic information can be found also in Jenkins plugin
Create the profile through in Gerrit web interface for your Jenkins user, and set up a SSH key for that user.
Gerrit web interface > Admin > Groups > Non-Interactive Users > Add your jenkins user.
Admin > Projects > ... > Access > Edit
Reference: refs/*
Read: ALLOW for Non-Interactive Users
Reference: refs/heads/*
Label Code-Review: -1, +1 for Non-Interactive Users
Label Verified: -1, +1 for Non-Interactive Users