jenkins-plugins

Google OAuth plugin for jenkins

与世无争的帅哥 提交于 2019-12-07 21:48:49
问题 I have installed the Google Login plugin on Jenkins 2.86: https://wiki.jenkins.io/display/JENKINS/Google+Login+Plugin and followed this guide: Login to the Google Developers Console Create a new project Under APIs & Auth -> Credentials, Create a new Client ID The application type should be "Web Application" The authorized redirect URLs should contain ${JENKINS_ROOT_URL}/securityRealm/finishLogin Enter the created Client Id and secret into the fields below. using the information from the

Putting a wildcard/regex expression in node/label restriction in Jenkins

。_饼干妹妹 提交于 2019-12-07 21:26:34
问题 In job configuration, there is a checkbox "Restrict where this project can be run". If you select it, there is an input field about Label Expression. Is there a way to insert of regex there, and not the exact name? If yes, could you provide an example of this? The whole concept behind this, is that I want to assign restrict jobs to slaves that are created automatically, with similar names 回答1: I don't believe that field can handle regular expressions, but you don't have to specify the name of

How to use the build cause in build name?

烂漫一生 提交于 2019-12-07 17:01:06
问题 When I trigger a job remotely using the API the job on jenkins say: "Started by remote host IP". But my jobs can trigger for different reasons and from different sources so it would be great if I in Jenkins could look at a job and directly see the trigger reason. I know I could pass a string parameter and then in each job view the parameters - but that's not very visible. I would like to preferably see it already in the list of all jobs. Something like: Reason: X Source: N . Is there any way

Jenkins artifact plugin does not archive empty directories

倖福魔咒の 提交于 2019-12-07 14:18:14
问题 I use the Jenkins artifact plugin to downward streams to use. My problem is that despite all my efforts, empty folders are not being archived. Apparently .svn files are also not archived. 回答1: Firstly, you are correct — empty directories cannot be archived, as a directory doesn't really make sense as an artifact in Jenkins. If you're copying the artifacts to another job, you can just create the directory in the other job, or ensure the directory is archived in the first place by adding a

Jenkins Groovy Postbuild use static file instead of script

亡梦爱人 提交于 2019-12-07 09:53:29
问题 Is it possible to load an external groovy script into the groovy post build plugin instead of pasting the script content into each job? We have approximately 200 jobs so updating them all is rather time consuming. I know that I could write a script to update the config files directly (as in this post: Add Jenkins Groovy Postbuild step to all jobs), but these jobs run 24x7 so finding a window when I can restart Jenkins or reload the config is problematic. Thanks! 回答1: Update : This is what

Create a Job DSL that creates a new job in the same View

大憨熊 提交于 2019-12-07 09:16:54
问题 I'm trying DSL job plugin to create new jobs in Jenkins. Is there a way to specify the view when creating the job? For example, I have a view NewJobsView . I want to create a DSL job called dsl-job and it is creating a new job "dsl-created-job1" DSL like this: job { name 'dsl-created-job1' //view 'NewJobsView' //or view {...} to specify the view } 回答1: What if you do: def myJob=job{name('test1')} def myJob2=job{name('test2')} view { name('view1') jobs{ name(myJob.name) name(myJob2.name) } }

Jenkins and TestNG results encoding

百般思念 提交于 2019-12-07 09:01:10
问题 I am use Jenkins to build my Maven project and post testng results using plugin. Have a problem with cyrillic symbols in report. It's look like: ��������. But cyrillic output in Jenkins console is OK. My pom.xml: <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

Jenkins and updating git submodules

不想你离开。 提交于 2019-12-07 08:53:40
问题 I am using Jenkins "Advanced sub-modules behaviour" and checked the "Recursively update sub modules" option. However I get the submodule only in an old revision. I would like to always have the head revision of the submodule. I found another option in "Advanced sub-modules behaviour" called "Update tracking submodules to tip of branch". This seems to use the --remote option. Will this solve the Problem? Any Ideas? 回答1: Based on the documentation page for submodule, it seems that that should

jenkins job on two slaves?

蹲街弑〆低调 提交于 2019-12-07 08:52:26
问题 We need to be able to run a Jenkins job that consumes two slaves. (Or, two jobs, if we can guarantee that they run at the same time, and it's possible for at least one to know what the other is.) The situation is that we have a heavy weight application that we need to run tests against. The tests run on one machine, the application runs on another. It's not practical to have them on the same host. Right now, we have a Jenkins job that uses a script to kick a dedicated application server up,

Jenkins JUnit Attachments Plugin throws 404 for attached files

你。 提交于 2019-12-07 08:08:51
问题 Currently I'm running a Maven 3 build with Selenium/WebDriver tests. Whenever a test fails, it will snap a screenshot and save it to the correct folder (for the plugin). When the job finishes, I can see all the attachments listed. I can also copy the attachments off of the Jenkins server and view them. However, whenever I try to view them in Jenkins, I'm seeing a 404 file not found exception. I've double checked the permissions of all the files involved, tried using both .jpg and .png