jenkins-plugins

Sonar Gerrit plugin not reporting results

和自甴很熟 提交于 2019-12-19 12:05:53
问题 We utilize the pipeline and after the build completes successfully we are running the following: bat "mvn sonar:sonar -B -s ${buildSettings} -Dsonar.analysis.mode=preview -Dsonar.skipDesign=true -Dsonar.report.export.path=sonar-report.json" sonarToGerrit(severity: 'Major', postScore: true, category: 'Code-Review', newIssuesOnly: true, issuesScore: '0', noIssuesScore: '0', changedLinesOnly: true) The below build log shows that it found a good number of issues but yet the issues to be commented

Sonar Gerrit plugin not reporting results

ⅰ亾dé卋堺 提交于 2019-12-19 12:05:29
问题 We utilize the pipeline and after the build completes successfully we are running the following: bat "mvn sonar:sonar -B -s ${buildSettings} -Dsonar.analysis.mode=preview -Dsonar.skipDesign=true -Dsonar.report.export.path=sonar-report.json" sonarToGerrit(severity: 'Major', postScore: true, category: 'Code-Review', newIssuesOnly: true, issuesScore: '0', noIssuesScore: '0', changedLinesOnly: true) The below build log shows that it found a good number of issues but yet the issues to be commented

run a Jenkins job on another Jenkins instance from the Jenkins job

旧时模样 提交于 2019-12-19 06:58:08
问题 I want to create a Jenkins job that starts other Jenkins jobs. That would be quite easy, because Jenkins Template Project Plugin allows us to create a build step of a type "use builders from another project". However, what makes my situation harder is that I have to start Jenkins jobs on other machines. Is there any standard way to do that? 回答1: In case you want only to trigger new build of Job You Have plenty of ways to accomplish it you can use remote access API and Trigger a request to

run a Jenkins job on another Jenkins instance from the Jenkins job

馋奶兔 提交于 2019-12-19 06:58:06
问题 I want to create a Jenkins job that starts other Jenkins jobs. That would be quite easy, because Jenkins Template Project Plugin allows us to create a build step of a type "use builders from another project". However, what makes my situation harder is that I have to start Jenkins jobs on other machines. Is there any standard way to do that? 回答1: In case you want only to trigger new build of Job You Have plenty of ways to accomplish it you can use remote access API and Trigger a request to

How do you configure the Jenkins “Create Job Advanced” plugin via groovy?

不羁岁月 提交于 2019-12-19 04:11:27
问题 My main goal is to use groovy to configure Jenkins and all the plugins, so that I don't need to manually configure Jenkins through the web interface, as the the post here was trying. Specifically, I'm trying to configure the Create Job Advanced plugin in Jenkins through groovy. When I try this code in the Jenkins Script Console: import org.codehaus.groovy.runtime.NullObject; // Jenkins instance def descriptor = jenkins.model.Jenkins.getInstance().getDescriptorByType(hudson.plugins

List all keep-forever builds in Jenkins?

谁说胖子不能爱 提交于 2019-12-19 02:38:25
问题 Is there an easy way in Jenkins to list all all builds marked as keep-forever? And then, ideally, one click to either unmark the build as keep-forever or to immediately delete it? In our process, we mark a build as keep-forever if it involves some specific type of failure; that's to keep Jenkins from automatically deleting over time. I need an easy way to get a list of all those keep-forever builds so they don't take up all our disk space over time. 回答1: The following XPath query against

Stopping Jenkins job in case newer one is started

巧了我就是萌 提交于 2019-12-19 00:56:08
问题 Is it possible to specify that, in case on job (A) is triggered more than once, that previous jobs are removed from queue, and only latest one is left in queue or started if there are enough free slots? Thanks in advance! 回答1: You can do it with a system Groovy Script run via Groovy Script Plugin. Such a script has direct access to Jenkins via its programming API. I do not see any other way. 回答2: use execute system groovy script step: import hudson.model.Result import jenkins.model

Maven installation settings not showing in Jenkins

淺唱寂寞╮ 提交于 2019-12-18 14:00:26
问题 I have just installed Jenkins 2.6 (as a fresh install) but I can't seem to find the Maven installation options. Previously I would just be able to go to Jenkins configuration and in the Maven section there would be an option for MAVEN_HOME and to install Maven automatically. However this doesn't appear to be present for me. I have the Maven integration plugin installed. How can I get these to show? 回答1: Since Jenkins 2.x you can find all the tool configurations (Maven, Ant, Gradle and even

How to set assembly version to Jenkins build number?

大憨熊 提交于 2019-12-18 12:37:12
问题 I am using "Change Assembly Version" plug-in in Jenkins to update all AssemblyInfo.cs files of my ASP.NET MVC project to apply version number during build process. If I set the "Assembly Version" value to a hard-coded one, this works very well. But my requirement is different - I would want to use a build number in the version number. For example, "1.1.0.25", where 25 is the build number and auto-generated by Jenkins. In short, the versions should be like "1.1.0.<>" I could do this in TFS

Jenkins Git plugin with https

孤街浪徒 提交于 2019-12-18 12:18:37
问题 I am trying to configure a Git project in Jenkins using the Git plugin. In the project configuration page I enter the repository URL in the Git configuration, which is an https URL (https://git.mycompany.com/git/MyProject.git). When I'm building the project however I get the following error: Started by user Hudson Administrator [EnvInject] - Loading node environment variables. Building in workspace /home/hudson/.hudson/jobs/MyProject/workspace Checkout:workspace / /home/hudson/.hudson/jobs