Re: How to get a list of jobs that are integrated with SonarQube

2020-05-25 Thread Jan Monterrubio
Can you post the config xml for one of the jobs? Hitting the config.xml
should let us see what props there are.

On Sun, May 24, 2020 at 11:12 Vijay Gongle  wrote:

> Thank you for responding.
> Can you help me completing the query;
>
> I would like to fetch the jobs which has the check mark "Prepare SonarQube
> Scanner environment" in Build Environment as shown below:
>
> [image: image.png]
>
> Thanks,
> Vijay
>
>
> On Sat, May 23, 2020 at 11:09 PM Jan Monterrubio 
> wrote:
>
>> You could iterate over the list of jobs and get the configuration traits
>> for them, and check if they have sonar cube, something like
>>
>> Jenkins.getInstance().items.each { it ->
>>
>> it.configuration?.steps // not sure what XML type the sonar cube step is,
>> if it has a step
>> }
>>
>>
>> On Sat, May 23, 2020 at 8:43 PM Vijay Gongle  wrote:
>>
>>> We have plenty of Jenkins job and most of them are running with
>>> SonarQube for analysis.
>>>
>>> How to find out; how many such jobs are running with SonarQube ?
>>>
>>> Thanks
>>> Vijay
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Jenkins Users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to jenkinsci-users+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/jenkinsci-users/d82c76df-ce71-45c3-8449-79a1b1f19bac%40googlegroups.com
>>> .
>>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Jenkins Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to jenkinsci-users+unsubscr...@googlegroups.com.
>>
> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9%2BG%3Df7AkSfE2v3xmQRUDcJvkThxNQ%2BL4nspcMsHrvhq5w%40mail.gmail.com
>> 
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/CAMrMyD%3Dx3_noyFk9%3D2LaboCoSUdiwwVhRopRw9d80yZ46bcJGQ%40mail.gmail.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9L6-4_bqHOmqB8bTtTNF%3DdbHPKFs%3Drjmm_r5Px%3Dy%3D5DSw%40mail.gmail.com.


How to get a list of jobs that are integrated with SonarQube

2020-05-25 Thread Vijay Gongle

> Thank you for responding. 
> Can you help me completing the query; 
> 
> I would like to fetch the jobs which has the check mark "Prepare SonarQube 
> Scanner environment" in Build Environment as shown below: 
> 
> 
> 
> Thanks, 
> Vijay
> 
> 
>> On Sat, May 23, 2020 at 11:09 PM Jan Monterrubio  
>> wrote:
>> You could iterate over the list of jobs and get the configuration traits for 
>> them, and check if they have sonar cube, something like
>> 
>> Jenkins.getInstance().items.each { it -> 
>> 
>> it.configuration?.steps // not sure what XML type the sonar cube step is, if 
>> it has a step 
>> }
>> 
>> 
>>> On Sat, May 23, 2020 at 8:43 PM Vijay Gongle  wrote:
>>> We have plenty of Jenkins job and most of them are running with SonarQube 
>>> for analysis. 
>>> 
>>> How to find out; how many such jobs are running with SonarQube ? 
>>> 
>>> Thanks 
>>> Vijay 
>>> 
>>> -- 
>>> You received this message because you are subscribed to the Google Groups 
>>> "Jenkins Users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send an 
>>> email to jenkinsci-users+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/d82c76df-ce71-45c3-8449-79a1b1f19bac%40googlegroups.com.
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Jenkins Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to jenkinsci-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9%2BG%3Df7AkSfE2v3xmQRUDcJvkThxNQ%2BL4nspcMsHrvhq5w%40mail.gmail.com.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/24E05FE8-FCFD-4E6D-92F4-E6CC25DBEB25%40gmail.com.


Re: Pipeline SCM trigger breaks

2020-05-25 Thread Jan Monterrubio
https://github.com/jenkinsci/git-plugin

The plugin lives there, so probably adding loggers to its root packages
might give you some info.

On Mon, May 25, 2020 at 06:38  wrote:

> Hi everyone,
>
>
>
> does anyone know, how I can get more information about the internal state
> of the Jenkins Git Plugin, especially the mapping from
> repositories/branches to pipelines, that need to be triggered on SCM
> changes?
>
> Are there classes, that I can add to a log recorder, files in Jenkins
> Home, anything?
>
>
>
> Thanks!
>
> Stefan
>
>
>
> *Von:* jenkinsci-users@googlegroups.com [mailto:
> jenkinsci-users@googlegroups.com] *Im Auftrag von *stefan.rademac...@tk.de
> *Gesendet:* Donnerstag, 14. Mai 2020 16:47
> *An:* jenkinsci-users@googlegroups.com
> *Betreff:* [SPAM-Verdacht] Pipeline SCM trigger breaks
>
>
>
> Hi,
>
>
>
> I have configured a multibranch pipeline (declarative), which checks out
> several git repositories and has pollSCM('') configured:
>
>
>
> I deleted and recreated the build for branch 'int'. The first two builds
> were triggered by branch indexing and manually by me.
>
> The 'Git Polling Log' from yesterday shows "Changes found" at the end of
> the polling log.
>
> Build #3 was successfully triggered yesterday, right after polling had run.
>
>
>
> Nothing changed in the meantime, but since then all calls to
>
>
> https://jenkins.dst.tk-inline.net:8181/git/notifyCommit?url=https://github.tk-online.net/TKeasy/arbeitgeberbeitrag=int
>
> ('TKeasy/arbeitgeberbeitrag' is one of the repositories, that were checked
> out by the pipeline and polled for changes)
>
> don't trigger a new polling.
>
> Instead I get
>
> No git jobs using repository:
> https://github.tk-online.net/TKeasy/arbeitgeberbeitrag and branches: int
>
> No Git consumers using SCM API plugin for:
> https://github.tk-online.net/TKeasy/arbeitgeberbeitrag
>
>
>
> "View Configuration" shows, that "poll SCM" is still checked.
>
>
>
> Logging output shows no "Triggering the polling of…", after
>
> Received notification from 10.252.62.17 ⇒
> https://jenkins.dst.tk-inline.net:8181/git/notifyCommit for uri =
> https://github.tk-online.net/TKeasy/arbeitgeberbeitrag ; sha1 = null ;
> branches = [int]
>
>
>
> For other branches, the polling is triggered successfully.
>
>
>
> Does anyone have a hint, how to trace down the cause of this issue further?
>
>
>
> Thanks and best regards
>
> Stefan
>
>
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/27e93ee328da4e66962363082d3afd7f%40tk.de
> 
> .
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/82617e38e6054d278da143aa4ba6525a%40tk.de
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CADgiF9%2BGNKTj9n0iB0c%3DxCNwP1agpxo%3DjyCNve9ACc%3D4fVHMRw%40mail.gmail.com.


AW: Pipeline SCM trigger breaks

2020-05-25 Thread Stefan.Rademacher
Hi everyone,

does anyone know, how I can get more information about the internal state of 
the Jenkins Git Plugin, especially the mapping from repositories/branches to 
pipelines, that need to be triggered on SCM changes?
Are there classes, that I can add to a log recorder, files in Jenkins Home, 
anything?

Thanks!
Stefan


Von: jenkinsci-users@googlegroups.com [mailto:jenkinsci-users@googlegroups.com] 
Im Auftrag von stefan.rademac...@tk.de
Gesendet: Donnerstag, 14. Mai 2020 16:47
An: jenkinsci-users@googlegroups.com
Betreff: [SPAM-Verdacht] Pipeline SCM trigger breaks

Hi,

I have configured a multibranch pipeline (declarative), which checks out 
several git repositories and has pollSCM('') configured:

I deleted and recreated the build for branch 'int'. The first two builds were 
triggered by branch indexing and manually by me.
The 'Git Polling Log' from yesterday shows "Changes found" at the end of the 
polling log.
Build #3 was successfully triggered yesterday, right after polling had run.

Nothing changed in the meantime, but since then all calls to
https://jenkins.dst.tk-inline.net:8181/git/notifyCommit?url=https://github.tk-online.net/TKeasy/arbeitgeberbeitrag=int
('TKeasy/arbeitgeberbeitrag' is one of the repositories, that were checked out 
by the pipeline and polled for changes)
don't trigger a new polling.
Instead I get
No git jobs using repository: 
https://github.tk-online.net/TKeasy/arbeitgeberbeitrag and branches: int
No Git consumers using SCM API plugin for: 
https://github.tk-online.net/TKeasy/arbeitgeberbeitrag

"View Configuration" shows, that "poll SCM" is still checked.

Logging output shows no "Triggering the polling of…", after
Received notification from 10.252.62.17 ⇒ 
https://jenkins.dst.tk-inline.net:8181/git/notifyCommit for uri = 
https://github.tk-online.net/TKeasy/arbeitgeberbeitrag ; sha1 = null ; branches 
= [int]

For other branches, the polling is triggered successfully.

Does anyone have a hint, how to trace down the cause of this issue further?

Thanks and best regards
Stefan


--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/27e93ee328da4e66962363082d3afd7f%40tk.de.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/82617e38e6054d278da143aa4ba6525a%40tk.de.


Re: Pull two repos into one build

2020-05-25 Thread Pete Kane


On Tuesday, 19 May 2020 17:42:00 UTC+1, Jérôme Godbout wrote:
>
> Simply checkout into Agent workspace subfolder:
>
>  
>
> dir(“source1”){
>
>checkout(…);
>
> }
>
>  
>
> dir(“source2”){
>
>   checkout(…);   
>
> }
>
>  
>
> I do 3-4 checkout for my builds (my common jenkins tools libraries repos, 
> my provisioning repos, my source code and his submodules and sometimes some 
> unit tests repos). My jenkinsfile is also into the CI repos so I can update 
> my C and apply it on any version of the source code.
>
>  
>
>  
>
> *From:* jenkins...@googlegroups.com  <
> jenkins...@googlegroups.com > *On Behalf Of *Felix Dorner
> *Sent:* May 19, 2020 8:47 AM
> *To:* jenkins...@googlegroups.com 
> *Subject:* Re: Pull two repos into one build
>
>  
>
> I used 
>
>  
>
>options { skipDefaultCheckout() } 
>
>  
>
> and then clone my projects into subdirectories with:
>
>  
>
> checkout([$class: 'GitSCM',
>
>branches: [[name: "*/${env.BRANCH_NAME}"]],
>
>doGenerateSubmoduleConfigurations: false,
>
>extensions: [[$class: 'RelativeTargetDirectory'
> ,
>
>   relativeTargetDir: subdir1],
>
>  ]]
>
> ///...
>
>  
>
> However, I did change that because I dont know how to handle pull requests 
> in a simple way with this approach. I now use git submodules, 
>
> so one is a submodule of the other.
>
>  
>
> Felix
>
>  
>
>  
>
> On Tue, May 19, 2020, 14:13 Pete Kane  > wrote:
>
> Title says it all really - I have an existing Pipeline SCM job setup which 
> utilises a Jenkins file in my Github repo ( the Jenkinsfile is itself a 
> pipeline ) All works perfectly.
>
>  
>
> I want to split my current repo ( seperation of concerns reasons ) into 
> two repos but still use the Jenkinsfile to pull them both into one build ( 
> does this make sense ? ) is this the correct way of doing things ?
>
>  
>
> TIA
>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to jenkins...@googlegroups.com .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/jenkinsci-users/354e3634-2e36-4de8-9664-af47450fe906%40googlegroups.com
>  
> 
> .
>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to jenkins...@googlegroups.com .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/jenkinsci-users/CALG%2B_hAUn49Kp38C%3DD-T4803fe4Mz2OuTrJ%3D43yZSpBgcb%3DedA%40mail.gmail.com
>  
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/d0578659-c6cc-4d2a-a815-39a492471801%40googlegroups.com.


Cannot connect to "cloud" (libvirt plugin)

2020-05-25 Thread Andreas Tscharner

Hello World,

I have 6 hosts where VMs for Jenkins are located. The VMs are all
QEMU/KVM and are handled by libvirt. After a Jenkins update I cannot
connect to 2 of these 6 hosts any longer.

Hosts: (all) Debian GNU/Linux 10.3
Jenkins: 2.222.3
Libvirt plugin: 1.8.5

I have a user "jenkins" on the Jenkins server and on the host with the
virtual machines. I copied the keys from Jenkins to the host and can ssh
from Jenkins to the host without password.
I can also (with the user jenkins) connect to qemu+ssh:///system
within the virtual shell virsh and perform commands.

But if I try to connect from Jenkins (in the Clouds Settings) I get the
error message:
com.nirima.libvirt.xdr.XDRException: authentication required

if the "Use Native Java libvirt client" is set.

And also on the host, I have the following entry in the log (syslog and 
debug):

May 25 10:59:59 aat-1 libvirtd[986]: authentication required

But in the auth.log, I get:
May 25 10:59:59 aat-1 sshd[10878]: Accepted password for jenkins from 
192.168.168.10 port 56746 ssh2
May 25 10:59:59 aat-1 sshd[10878]: pam_unix(sshd:session): session 
opened for user jenkins by (uid=0)

May 25 10:59:59 aat-1 systemd-logind[501]: New session 341 of user jenkins.
May 25 10:59:59 aat-1 systemd: pam_unix(systemd-user:session): session 
opened for user jenkins by (uid=0)



If "Use Native Java libvirt client" is not checked, I get an "ERROR" 
link and if I click on it, a huge Java traceback is displayed, starting 
with:
java.lang.NoClassDefFoundError: Could not initialize class 
org.libvirt.Connect
	at 
hudson.plugins.libvirt.lib.libvirt.LibVirtConnectImpl.(LibVirtConnectImpl.java:23)
	at 
hudson.plugins.libvirt.lib.ConnectionBuilder.build(ConnectionBuilder.java:97)
	at 
hudson.plugins.libvirt.Hypervisor$DescriptorImpl.doTestConnection(Hypervisor.java:454)



I noticed that the libvirt-slave plugin is compiled using Java 5. Is it 
too old?


What can I do to solve my problem? Any ideas?

TIA and best regards
Andreas
--
Andreas Tscharner sternenfe...@gmail.com

Gordon's Law:
If you think you have the solution, the question was poorly phrased.

--
You received this message because you are subscribed to the Google Groups "Jenkins 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/a7258141-67ab-b114-ca58-7c49e88835f6%40gmail.com.