Re: Does 'scm checkout' always give the same result with parallel builds in JenkinsFiles ?

2016-09-21 Thread sleipnir

Thanks for the quick reply.
Any info about the recommended way to get the sha that was actually used ?

-- 
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/23b09958-5f34-46ac-b0f8-715be4fd5f06%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Does 'scm checkout' always give the same result with parallel builds in JenkinsFiles ?

2016-09-21 Thread Mark Waite
The intent of the checkout scm step is that it takes a single revision, and
uses that revision for the duration of the job.

Unfortunately, a bug was found during discussions after Jenkins World which
seem to indicate that there area cases where git plugin 2.5.3 and beyond
risks not checking out the same revision for every use of "checkout scm"
within a single job.

The fix is in
https://github.com/jenkinsci/git-plugin/commit/cd6c7cdcba29f5c3615ad35d690678ebd5694348
 .

Tests which confirm the fix has the desired behavior are in
https://github.com/jenkinsci/git-plugin/commit/e15a431a62781c6081c57354a33a7e148a4452a1
 and
https://github.com/jenkinsci/git-plugin/commit/fcbdc768536c2c5286680734bbedc64fec0103c2
 .

Those fixes have not yet been included in a plugin release.

Mark Waite

On Wed, Sep 21, 2016 at 9:38 PM sleipnir  wrote:

> Hi
>
> I was playing with JenkinsFiles and Organization folders (multi-branch
> pipeline) and I was wondering:
> Is there is any guarantee the 'checkout scm' command would checkout the
> exact same revision on all node, even if new commits are pushed before the
> build is finished ?
> Also, I saw an environment variable that gives the branch name
> (BRANCH_NAME) but nothing for the revision.
> Do I have to call a git command after the 'checkout scm' command to
> extract the sha1 so I can stamp the build output properly ? (something like
> 'git rev-parse HEAD')
>
> Here's a test jenkinsfile I'm using:
>
> stage 'build'
>
> parallel (
>   BuildDebug: { node {
> checkout scm
>
>
>  }},
>   BuildRelease: { node {
> checkout scm
>
>  }}
> )
>
> Thanks
>
> --
> 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/4fb3bb94-a954-4e2e-aecf-5786432aa08b%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CAO49JtFOnhAy_1Xs%2BWA%3DbzGw4X6t6EeAs9i9g3y0%3DRyJtiCX4w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Does 'scm checkout' always give the same result with parallel builds in JenkinsFiles ?

2016-09-21 Thread sleipnir
Hi

I was playing with JenkinsFiles and Organization folders (multi-branch 
pipeline) and I was wondering:
Is there is any guarantee the 'checkout scm' command would checkout the 
exact same revision on all node, even if new commits are pushed before the 
build is finished ?
Also, I saw an environment variable that gives the branch name 
(BRANCH_NAME) but nothing for the revision. 
Do I have to call a git command after the 'checkout scm' command to extract 
the sha1 so I can stamp the build output properly ? (something like 'git 
rev-parse HEAD')

Here's a test jenkinsfile I'm using:

stage 'build'

parallel (
  BuildDebug: { node {
checkout scm

 
 }},
  BuildRelease: { node {
checkout scm
 
 }}
)

Thanks

-- 
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/4fb3bb94-a954-4e2e-aecf-5786432aa08b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Can't download plugins - HTTP 302 redirect

2016-09-21 Thread Daniel Beck
Turns out this was https://issues.jenkins-ci.org/browse/JENKINS-38340 and we 
removed the mirror from the list, as its admins don't want to serve files via 
HTTP.

> On 19.09.2016, at 20:56, Baptiste Mathus  wrote:
> 
> I think it's https://issues.jenkins-ci.org/browse/JENKINS-8028 but surprised 
> it's still active. Pretty sure I saw fixes about this. Maybe it was on some 
> other parts like Tools.
> 
> 2016-09-19 6:10 GMT+02:00 Corey Wei :
> anyone can help?
> 
> 
> On Sunday, September 18, 2016 at 4:43:12 PM UTC+8, Corey Wei wrote:
> Hi Croy,
> 
> I just downloaded a hpi from the mirror and the file's good.
> 
> The problem is that Jenkins server doesn't  follow 302 redirects to download 
> the correct file but always downloads a "302 redirect" response file.
> 
> # a 302 redirect file
> $ cat git-server.jpi.tmp
> 
> 
> 302 Found
> 
> Found
> The document has moved  href="https://mirrors.tuna.tsinghua.edu.cn/jenkins/plugins/git-server/1.7/git-server.hpi;>here.
> 
> 
> # file can be downloaded  correctly via wget
> $ wget -v 
> http://updates.jenkins-ci.org/download/plugins/git-server/1.7/git-server.hpi
> --2016-09-18 15:49:54--  
> http://updates.jenkins-ci.org/download/plugins/git-server/1.7/git-server.hpi
> Resolving updates.jenkins-ci.org... 52.202.51.185
> Connecting to updates.jenkins-ci.org|52.202.51.185|:80... connected.
> HTTP request sent, awaiting response... 302 Found
> Location: http://mirrors.jenkins-ci.org/plugins/git-server/1.7/git-server.hpi 
> [following]
> --2016-09-18 15:49:55--  
> http://mirrors.jenkins-ci.org/plugins/git-server/1.7/git-server.hpi
> Resolving mirrors.jenkins-ci.org... 52.202.51.185
> Reusing existing connection to updates.jenkins-ci.org:80.
> HTTP request sent, awaiting response... 302 Found
> Location: 
> https://mirrors.tuna.tsinghua.edu.cn/jenkins/plugins/git-server/1.7/git-server.hpi
>  [following]
> --2016-09-18 15:49:58--  
> https://mirrors.tuna.tsinghua.edu.cn/jenkins/plugins/git-server/1.7/git-server.hpi
> Resolving mirrors.tuna.tsinghua.edu.cn... 166.111.206.63, 
> 2402:f000:1:416:166:111:206:63
> Connecting to mirrors.tuna.tsinghua.edu.cn|166.111.206.63|:443... connected.
> HTTP request sent, awaiting response... 200 OK
> Length: 40729 (40K) [application/octet-stream]
> Saving to: “git-server.hpi.1”
> 
> 100%[===>]
>  40,729  --.-K/s   in 0s
> 
> 
> 2016-09-18 15:49:58 (188 MB/s) - “git-server.hpi.1” saved [40729/40729]
> 
> 
> 
> On Sunday, September 18, 2016 at 2:59:06 PM UTC+8, R Tyler Croy wrote:
> (replies inline) 
> 
> On Sat, 17 Sep 2016, Corey Wei wrote: 
> 
> > Hi, 
> > 
> > My Jenkins 2.22 is working with Tomcat. There are some errors while I tried 
> > to install plugins like this: 
> > 
> > 18-Sep-2016 11:17:05.590 SEVERE [Update center installer thread [#1]] 
> > hudson.model.UpdateCenter$DownloadJob.run Failed to install GIT server 
> > Plugin 
> >  java.io.IOException: Downloaded file 
> > /home/deploy/.jenkins2/plugins/git-server.jpi.tmp does not match expected 
> > SHA-1, expected 'LoG8X55ycVzgPjwTtCA/iKb7lvw=', actual 
> > 'Lbk3pB/mu/UlYJO4o2ttQkZ+mvs=' 
> 
> 
> I recently added a mirror located in China 
> (https://issues.jenkins-ci.org/browse/INFRA-924). 
> 
> Would you mind downloading some files and comparing between the mirror you're 
> hitting and: http://ftp-nyc.osuosl.org/pub/jenkins/ 
> 
> 
> If that mirror is serving corrupted artifacts I will remove it from the 
> rotation immediately. 
> 
> 
> 
> > at 
> > hudson.model.UpdateCenter.verifyChecksums(UpdateCenter.java:1799) 
> > at hudson.model.UpdateCenter.access$1100(UpdateCenter.java:147) 
> > at 
> > hudson.model.UpdateCenter$InstallationJob.replace(UpdateCenter.java:1950) 
> > at 
> > hudson.model.UpdateCenter$UpdateCenterConfiguration.install(UpdateCenter.java:1194)
> >  
> > at 
> > hudson.model.UpdateCenter$DownloadJob._run(UpdateCenter.java:1669) 
> > at 
> > hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1864) 
> > at 
> > hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1640) 
> > at 
> > java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) 
> > at java.util.concurrent.FutureTask.run(FutureTask.java:266) 
> > at 
> > hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)
> >  
> > at java.lang.Thread.run(Thread.java:745) 
> > 
> > $ cat ~/.jenkins2/plugins/git-server.jpi.tmp 
> >  
> >  
> > 302 Found 
> >  
> > Found 
> > The document has moved  > href="https://mirrors.tuna.tsinghua.edu.cn/jenkins/plugins/git-server/1.7/git-server.hpi;>here.
> >  
> >  
> > 
> > Looks like it redirects to a mirror update center. 
> > 
> > Any comments would be appreciated. 
> > 
> > Thanks 
> > 
> > -- 
> > You received this message because you are subscribed to the Google Groups 
> > 

Re: Will workspace cleanup affect Changes tracking?

2016-09-21 Thread Daniel Beck

> On 19.09.2016, at 19:59, Sam K  wrote:
> 
> Will having a 'deleteDir()' in the jobs affect the Jenkins changes tracking?  
> Does Jenkins use the workspace for tracking the changes?  

Yes and no. A checkout may be necessary to record the checked out 
revisions/commits, but you can clean up the workspace after that (e.g. after 
the build is otherwise finished).

-- 
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/B23667AE-C310-4FE5-A8B4-1BAD60DC6A07%40beckweb.net.
For more options, visit https://groups.google.com/d/optout.


How to integrate Github with Jenkin in version 2.7 (for webhook to trigger builds whenever there is code checkin)?

2016-09-21 Thread Sean Bigdatafun
I found this link is quite 
informative 
https://www.cloudbees.com/blog/better-integration-between-jenkins-and-github-github-jenkins-plugin
 
to elaborate the details. However, it seems that it does not reflect the 
administrative UI for Jenkin 2.7. I have my github plugin installed.

Specifically, "In the GitHub Web Hook section select the Let Jenkins 
auto-manage hook URLs option.". I can't find the Github Web Hook section in 
my administrative UI.

Is there an updated instruction page for this subject?



-- 
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/aca76d7e-51be-4e11-a427-8ab108c0e58f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: terminate pipeline parallal on first failure

2016-09-21 Thread Michael Neale
If it isn't, please do raise a ticket as it is an important feature of 
parallel for people to know about. 

On Thursday, September 22, 2016 at 6:50:02 AM UTC+10, Baptiste Mathus wrote:
>
> o/ Didn't check, but this should be in the "Snippet Generator".
>
>
>
> 2016-09-21 22:38 GMT+02:00 Åsmund Østvold 
> :
>
>> Thank you Cuong and Michael,
>>
>> IIRC my Jenkins install do not give me the choice for "failFast: true" 
>> that I was searching for. Will check tomorrow. But if somebody has a link 
>> to the "full" syntax I would love to have it.
>>
>> Asmund
>>
>> On Sep 21, 2016 08:34, "Michael Neale" > > wrote:
>>
>>> There is also: https://jenkins.io/doc/pipeline/
>>>
>>> but generally for the steps - if you open a job to edit, you should see 
>>> either near the pipeline text area or on the left a "Pipeline Syntax" link 
>>> you can open in a new tab. It gives you a choice of steps that will build 
>>> the syntax out for you as things you can copy and paste.
>>>
>>> On Wednesday, September 21, 2016 at 1:42:40 PM UTC+10, Cuong Tran wrote:

 The reference link is right on any pipeline job.  You should see a 
 "Pipeline Syntax" link, click on that will give a list of known steps, the 
 click on the question icon will give you an example.


 On Tuesday, September 20, 2016 at 1:57:43 PM UTC-7, asmundo wrote:
>
> Thank you Baptiste!
>
> Tested and it worked. You owe you a beer! 
>
> I am new to pipeline programming. I worked several hours today on this 
> and other pipeline related work. Could you please point me to the 
> documentation of this syntax? I must have been looking in the wrong 
> location. 
>
> Cheers
>
>
>
> On Tue, Sep 20, 2016 at 10:47 PM, Baptiste Mathus  
> wrote:
>
>> Hi,
>>
>>  stage('tests') {
>> parallel 'longTests': {
>> build job: 'testjob1', quietPeriod: 0
>> }, 'shortTests':{
>> // this will fail 1 sec
>> build job: 'testjob2', quietPeriod: 0
>> }, failFast: true   
>>
>> }
>>
>> Cheers
>>
>> 2016-09-20 22:43 GMT+02:00 Åsmund Østvold :
>>
>>> hi All,
>>>
>>> Do anybody have an example or a pointer to how one could terminate a 
>>> parallel pipeline section on first failure?
>>>
>>> The use case is that I have 14 tests in a checkin regression 
>>> pipeline. Some tests take 2 min some take 40 min. To speed up feedback 
>>> to 
>>> the users we want to give feed back ASAP if a test did fail. 
>>>
>>> My test pipeline is:
>>>
>>> stage('tests') {
>>> parallel 'longTests': {
>>> build job: 'testjob1', quietPeriod: 0
>>> }, 'shortTests':{
>>> // this will fail 1 sec
>>> build job: 'testjob2', quietPeriod: 0
>>> }
>>> }
>>>
>>> My current "pipeline" (Build-flow) is able to do this with a ugly 
>>> hack:
>>>
>>> import static hudson.model.Result.FAILURE
>>> import groovy.time.*
>>>
>>> parallel (
>>>   { b = build("testjob1")
>>> if (b.getResult().toString() != "SUCCESS") {
>>> upstream.getExecutor().interrupt(FAILURE)
>>>}
>>>   },
>>>   { b = build("testjob2"])
>>> if (b.getResult().toString() != "SUCCESS") {
>>> upstream.getExecutor().interrupt(FAILURE)
>>>}
>>>   }
>>> )
>>>
>>> Regard,
>>> Asmund
>>>
>>> -- 
>>> 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-use...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/CA%2BzfM3Bq0x7djYpWaXfvSbHrFf2DuGJeZ8fEsVskT%3DDfTeKq2w%40mail.gmail.com
>>>  
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>> -- 
>> 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-use...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/CANWgJS76kD0W0dTTPeF3P0xXtC1UomAHJ6Swtbog68%3DPDSWyPQ%40mail.gmail.com
>>  
>> 
>> .
>> For more options, visit 

Re: locks vs stage w/concurrency

2016-09-21 Thread David Karlsen
Thanks - last I checked it was not finished - now it is! :)

2016-09-21 23:37 GMT+02:00 Michael Kobit :

> I believe the stage step with concurrency has been deprecated so I would
> avoid using that.
>
> It sounds like you are looking for https://issues.jenkins-ci.org/
> plugins/servlet/mobile#issue/JENKINS-27039 (milestone step).
>
> --
> 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/c758e13a-c59c-4c8b-a0a6-36645c57477c%40googlegroups.
> com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--
David J. M. Karlsen - http://www.linkedin.com/in/davidkarlsen

-- 
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/CAGO7Ob0V0yTXAZ4JCb2bJ7JAowbBrAM8OUh4A27rr3Rbho%2BwiA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


RE: Jenkins in container is offline

2016-09-21 Thread Alex Sun
Update:

 

I provisioned a VM on cloud and now the container is connected to Internet. The 
below ones that cannot connect to Internet are hosted in VMs provisioned on 
hyper-v of  local machines.

 

From: Alex Sun [mailto:suen...@gmail.com] 
Sent: Wednesday, September 21, 2016 3:43 PM
To: jenkinsci-users@googlegroups.com
Subject: RE: Jenkins in container is offline

 

Merging thread…

 

Both host and docker are latest version. 

 



From: bmat...@gmail.com   [mailto:bmat...@gmail.com] 
On Behalf Of Baptiste Mathus
Sent: Wednesday, September 21, 2016 1:36 PM
To: Hung Suen  >; 
jenkinsci-users@googlegroups.com  
Subject: Re: Jenkins hosted in container is offline

 

(Switching to users ML)

That rings an distant old bell to me. Having no network in the container. I 
think I had that in the past. Something about resolv.conf being handled with 
the local DNS manager on Ubuntu or something, had to force or override the DNS 
to let containers have network access.

 

What is your host platform? What is the output of docker info/docker version?

 

 

 

From: bmat...@gmail.com   [mailto:bmat...@gmail.com] 
On Behalf Of Baptiste Mathus
Sent: Wednesday, September 21, 2016 2:46 PM
To: jenkinsci-users@googlegroups.com  
Subject: Re: Jenkins in container is offline

 

@Nicolas please see the other corresponding thread to keep things together. And 
let's leave that one die.

 

Le 21 sept. 2016 11:25 PM, "nicolas de loof"  > a écrit :

Try running this :

 

docker run --rm -it jenkins bash

jenkins@b2b041c448b1:/$ ping google.com  

PING google.com   (172.217.19.142): 56 data bytes

64 bytes from 172.217.19.142  : icmp_seq=0 ttl=37 
time=0.147 ms

64 bytes from 172.217.19.142  : icmp_seq=1 ttl=37 
time=0.338 ms

^C--- google.com   ping statistics ---

 

 

 

 

2016-09-21 22:25 GMT+02:00 Hung Suen  >:

I posted the topic to Jenkins developers. Should have posted it here.

https://groups.google.com/d/topic/jenkinsci-dev/LCPjMbKCmGM/discussion

 

-- 
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/b3c1a12a-f2f7-44ab-9227-9546cd228853%40googlegroups.com
 

 .
For more options, visit https://groups.google.com/d/optout.

 

-- 
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/CANMVJzmFh31Nwm13nBzHQOZfxRB-a12npV6h2Y3qwA_2Bc%3DcRw%40mail.gmail.com
 

 .
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to a topic in the Google 
Groups "Jenkins Users" group.
To unsubscribe from this topic, visit 
https://groups.google.com/d/topic/jenkinsci-users/IV0MjGlTr_8/unsubscribe.
To unsubscribe from this group and all its topics, 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/CANWgJS7tKbJ9_U%2Bs4t4z2662eT0WE65NK0cQ%2BYSezJUUVjzHZQ%40mail.gmail.com
 

 .
For more options, visit https://groups.google.com/d/optout.

-- 
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/007501d2145c%24b24c0940%2416e41bc0%24%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins in container is offline

2016-09-21 Thread Baptiste Mathus
@Nicolas please see the other corresponding thread to keep things together.
And let's leave that one die.

Le 21 sept. 2016 11:25 PM, "nicolas de loof"  a
écrit :

> Try running this :
>
> *docker run --rm -it jenkins bash*
>
> jenkins@b2b041c448b1:/$ *ping google.com *
>
> PING google.com (172.217.19.142): 56 data bytes
>
> 64 bytes from 172.217.19.142: icmp_seq=0 ttl=37 time=0.147 ms
>
> 64 bytes from 172.217.19.142: icmp_seq=1 ttl=37 time=0.338 ms
>
> ^C--- google.com ping statistics ---
>
>
>
>
>
> 2016-09-21 22:25 GMT+02:00 Hung Suen :
>
>> I posted the topic to Jenkins developers. Should have posted it here.
>> https://groups.google.com/d/topic/jenkinsci-dev/LCPjMbKCmGM/discussion
>>
>> --
>> 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/ms
>> gid/jenkinsci-users/b3c1a12a-f2f7-44ab-9227-9546cd228853%
>> 40googlegroups.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> 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/CANMVJzmFh31Nwm13nBzHQOZfxRB-
> a12npV6h2Y3qwA_2Bc%3DcRw%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CANWgJS7tKbJ9_U%2Bs4t4z2662eT0WE65NK0cQ%2BYSezJUUVjzHZQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


RE: Jenkins hosted in container is offline

2016-09-21 Thread Alex Sun
Both host and docker are latest version. 

 



From: bmat...@gmail.com [mailto:bmat...@gmail.com] On Behalf Of Baptiste Mathus
Sent: Wednesday, September 21, 2016 1:36 PM
To: Hung Suen ; jenkinsci-users@googlegroups.com
Subject: Re: Jenkins hosted in container is offline

 

(Switching to users ML)

That rings an distant old bell to me. Having no network in the container. I 
think I had that in the past. Something about resolv.conf being handled with 
the local DNS manager on Ubuntu or something, had to force or override the DNS 
to let containers have network access.

 

What is your host platform? What is the output of docker info/docker version?

 

2016-09-21 22:28 GMT+02:00 Hung Suen  >:

Thanks Baptiste. The Internet can be reached from my machine. As whether it can 
be reached from container, I tried different approaches but none of the 
commands can be run inside the container. I mean, commands like ifconfig/ping 
all returned errors like "bash: ifconfig: command not found"

On Wednesday, September 21, 2016 at 1:12:34 PM UTC-7, Baptiste Mathus wrote:

Oh, and please, use the users list if you wish to have answers. Thanks

 

2016-09-21 22:07 GMT+02:00 Baptiste Mathus  >:

Are you behind a corporate proxy? Can Internet be reached from your machine, 
and more specifically from that container?

 

Cheers

 

2016-09-21 20:36 GMT+02:00 'Huanhuan Sun' via Jenkins Developers 
 >:

Hi,

 

I tried to set up a Jenkins container. I pulled the official docker image: 
jenkins and create a container off it. The commands I used:

docker pull jenkins

docker run -d -p 8090:8080 -t jenkins

 

I could open the Jenkins dashboard at port 8090 but on the dashboard it showed 
Jenkins is offline. I entered bash of this container:

docker exec -it –user root  bash

and tried to restart it:

service jenkins restart

The output was it cannot find the command jenkins.

 

Two questions:

1.   Why is this offline and how to bring it online?

2.   Is containerized Jenkins different from Linux Jenkins? Why I cannot 
use normal jenkins command like restart/start/stop/status?

 

Thanks a lot,

Huan

 

  

 

 

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-de...@googlegroups.com  .
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/MWHPR03MB26051CF398DB445BFE2F4E84B4F60%40MWHPR03MB2605.namprd03.prod.outlook.com
 

 .
For more options, visit https://groups.google.com/d/optout.

 

 

 

-- 
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/005701d21450%24ef362d10%24cda28730%24%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Compiling Jenkins from source

2016-09-21 Thread Daniel Beck

> On 21.09.2016, at 21:38, Radcliff, Allen  wrote:
> 
> I run a "git branch -r", but do not see a branch for version 1.658.  Please 
> advise.

1.568 has never been publicly announced and only exists due to some process 
testing. What do you need that for?

-- 
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/CD0DE7F7-95BD-44C2-9732-920A5BE712E5%40beckweb.net.
For more options, visit https://groups.google.com/d/optout.


locks vs stage w/concurrency

2016-09-21 Thread Michael Kobit
I believe the stage step with concurrency has been deprecated so I would avoid 
using that.

It sounds like you are looking for 
https://issues.jenkins-ci.org/plugins/servlet/mobile#issue/JENKINS-27039 
(milestone step).

-- 
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/c758e13a-c59c-4c8b-a0a6-36645c57477c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins in container is offline

2016-09-21 Thread nicolas de loof
Try running this :

*docker run --rm -it jenkins bash*

jenkins@b2b041c448b1:/$ *ping google.com *

PING google.com (172.217.19.142): 56 data bytes

64 bytes from 172.217.19.142: icmp_seq=0 ttl=37 time=0.147 ms

64 bytes from 172.217.19.142: icmp_seq=1 ttl=37 time=0.338 ms

^C--- google.com ping statistics ---





2016-09-21 22:25 GMT+02:00 Hung Suen :

> I posted the topic to Jenkins developers. Should have posted it here.
> https://groups.google.com/d/topic/jenkinsci-dev/LCPjMbKCmGM/discussion
>
> --
> 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/b3c1a12a-f2f7-44ab-9227-9546cd228853%40googlegroups.
> com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CANMVJzmFh31Nwm13nBzHQOZfxRB-a12npV6h2Y3qwA_2Bc%3DcRw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: terminate pipeline parallal on first failure

2016-09-21 Thread Baptiste Mathus
o/ Didn't check, but this should be in the "Snippet Generator".



2016-09-21 22:38 GMT+02:00 Åsmund Østvold :

> Thank you Cuong and Michael,
>
> IIRC my Jenkins install do not give me the choice for "failFast: true"
> that I was searching for. Will check tomorrow. But if somebody has a link
> to the "full" syntax I would love to have it.
>
> Asmund
>
> On Sep 21, 2016 08:34, "Michael Neale"  wrote:
>
>> There is also: https://jenkins.io/doc/pipeline/
>>
>> but generally for the steps - if you open a job to edit, you should see
>> either near the pipeline text area or on the left a "Pipeline Syntax" link
>> you can open in a new tab. It gives you a choice of steps that will build
>> the syntax out for you as things you can copy and paste.
>>
>> On Wednesday, September 21, 2016 at 1:42:40 PM UTC+10, Cuong Tran wrote:
>>>
>>> The reference link is right on any pipeline job.  You should see a
>>> "Pipeline Syntax" link, click on that will give a list of known steps, the
>>> click on the question icon will give you an example.
>>>
>>>
>>> On Tuesday, September 20, 2016 at 1:57:43 PM UTC-7, asmundo wrote:

 Thank you Baptiste!

 Tested and it worked. You owe you a beer!

 I am new to pipeline programming. I worked several hours today on this
 and other pipeline related work. Could you please point me to the
 documentation of this syntax? I must have been looking in the wrong
 location.

 Cheers



 On Tue, Sep 20, 2016 at 10:47 PM, Baptiste Mathus 
 wrote:

> Hi,
>
>  stage('tests') {
> parallel 'longTests': {
> build job: 'testjob1', quietPeriod: 0
> }, 'shortTests':{
> // this will fail 1 sec
> build job: 'testjob2', quietPeriod: 0
> }, failFast: true
>
> }
>
> Cheers
>
> 2016-09-20 22:43 GMT+02:00 Åsmund Østvold :
>
>> hi All,
>>
>> Do anybody have an example or a pointer to how one could terminate a
>> parallel pipeline section on first failure?
>>
>> The use case is that I have 14 tests in a checkin regression
>> pipeline. Some tests take 2 min some take 40 min. To speed up feedback to
>> the users we want to give feed back ASAP if a test did fail.
>>
>> My test pipeline is:
>>
>> stage('tests') {
>> parallel 'longTests': {
>> build job: 'testjob1', quietPeriod: 0
>> }, 'shortTests':{
>> // this will fail 1 sec
>> build job: 'testjob2', quietPeriod: 0
>> }
>> }
>>
>> My current "pipeline" (Build-flow) is able to do this with a ugly
>> hack:
>>
>> import static hudson.model.Result.FAILURE
>> import groovy.time.*
>>
>> parallel (
>>   { b = build("testjob1")
>> if (b.getResult().toString() != "SUCCESS") {
>> upstream.getExecutor().interrupt(FAILURE)
>>}
>>   },
>>   { b = build("testjob2"])
>> if (b.getResult().toString() != "SUCCESS") {
>> upstream.getExecutor().interrupt(FAILURE)
>>}
>>   }
>> )
>>
>> Regard,
>> Asmund
>>
>> --
>> 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-use...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/jenkinsci-users/CA%2BzfM3B
>> q0x7djYpWaXfvSbHrFf2DuGJeZ8fEsVskT%3DDfTeKq2w%40mail.gmail.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> 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-use...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/CANWgJS76k
> D0W0dTTPeF3P0xXtC1UomAHJ6Swtbog68%3DPDSWyPQ%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

 --
>> 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/ms
>> 

Re: terminate pipeline parallal on first failure

2016-09-21 Thread Åsmund Østvold
Thank you Cuong and Michael,

IIRC my Jenkins install do not give me the choice for "failFast: true" that
I was searching for. Will check tomorrow. But if somebody has a link to the
"full" syntax I would love to have it.

Asmund

On Sep 21, 2016 08:34, "Michael Neale"  wrote:

> There is also: https://jenkins.io/doc/pipeline/
>
> but generally for the steps - if you open a job to edit, you should see
> either near the pipeline text area or on the left a "Pipeline Syntax" link
> you can open in a new tab. It gives you a choice of steps that will build
> the syntax out for you as things you can copy and paste.
>
> On Wednesday, September 21, 2016 at 1:42:40 PM UTC+10, Cuong Tran wrote:
>>
>> The reference link is right on any pipeline job.  You should see a
>> "Pipeline Syntax" link, click on that will give a list of known steps, the
>> click on the question icon will give you an example.
>>
>>
>> On Tuesday, September 20, 2016 at 1:57:43 PM UTC-7, asmundo wrote:
>>>
>>> Thank you Baptiste!
>>>
>>> Tested and it worked. You owe you a beer!
>>>
>>> I am new to pipeline programming. I worked several hours today on this
>>> and other pipeline related work. Could you please point me to the
>>> documentation of this syntax? I must have been looking in the wrong
>>> location.
>>>
>>> Cheers
>>>
>>>
>>>
>>> On Tue, Sep 20, 2016 at 10:47 PM, Baptiste Mathus 
>>> wrote:
>>>
 Hi,

  stage('tests') {
 parallel 'longTests': {
 build job: 'testjob1', quietPeriod: 0
 }, 'shortTests':{
 // this will fail 1 sec
 build job: 'testjob2', quietPeriod: 0
 }, failFast: true

 }

 Cheers

 2016-09-20 22:43 GMT+02:00 Åsmund Østvold :

> hi All,
>
> Do anybody have an example or a pointer to how one could terminate a
> parallel pipeline section on first failure?
>
> The use case is that I have 14 tests in a checkin regression pipeline.
> Some tests take 2 min some take 40 min. To speed up feedback to the users
> we want to give feed back ASAP if a test did fail.
>
> My test pipeline is:
>
> stage('tests') {
> parallel 'longTests': {
> build job: 'testjob1', quietPeriod: 0
> }, 'shortTests':{
> // this will fail 1 sec
> build job: 'testjob2', quietPeriod: 0
> }
> }
>
> My current "pipeline" (Build-flow) is able to do this with a ugly hack:
>
> import static hudson.model.Result.FAILURE
> import groovy.time.*
>
> parallel (
>   { b = build("testjob1")
> if (b.getResult().toString() != "SUCCESS") {
> upstream.getExecutor().interrupt(FAILURE)
>}
>   },
>   { b = build("testjob2"])
> if (b.getResult().toString() != "SUCCESS") {
> upstream.getExecutor().interrupt(FAILURE)
>}
>   }
> )
>
> Regard,
> Asmund
>
> --
> 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-use...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/CA%2BzfM3B
> q0x7djYpWaXfvSbHrFf2DuGJeZ8fEsVskT%3DDfTeKq2w%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

 --
 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-use...@googlegroups.com.
 To view this discussion on the web visit https://groups.google.com/d/ms
 gid/jenkinsci-users/CANWgJS76kD0W0dTTPeF3P0xXtC1UomAHJ6Swtbo
 g68%3DPDSWyPQ%40mail.gmail.com
 
 .
 For more options, visit https://groups.google.com/d/optout.

>>>
>>> --
> 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/56293faf-3380-4601-ab74-ccf8710f4c56%40googlegroups.
> com
> 
> .
> For more options, visit 

Re: Jenkins hosted in container is offline

2016-09-21 Thread Baptiste Mathus
(Switching to users ML)
That rings an distant old bell to me. Having no network in the container. I
think I had that in the past. Something about resolv.conf being handled
with the local DNS manager on Ubuntu or something, had to force or override
the DNS to let containers have network access.

What is your host platform? What is the output of docker info/docker
version?

2016-09-21 22:28 GMT+02:00 Hung Suen :

> Thanks Baptiste. The Internet can be reached from my machine. As whether
> it can be reached from container, I tried different approaches but none of
> the commands can be run inside the container. I mean, commands like
> ifconfig/ping all returned errors like "bash: ifconfig: command not found"
>
> On Wednesday, September 21, 2016 at 1:12:34 PM UTC-7, Baptiste Mathus
> wrote:
>>
>> Oh, and please, use the users list if you wish to have answers. Thanks
>>
>> 2016-09-21 22:07 GMT+02:00 Baptiste Mathus :
>>
>>> Are you behind a corporate proxy? Can Internet be reached from your
>>> machine, and more specifically from that container?
>>>
>>> Cheers
>>>
>>> 2016-09-21 20:36 GMT+02:00 'Huanhuan Sun' via Jenkins Developers <
>>> jenkin...@googlegroups.com>:
>>>
 Hi,



 I tried to set up a Jenkins container. I pulled the official docker
 image: jenkins and create a container off it. The commands I used:

 docker pull jenkins

 docker run -d -p 8090:8080 -t jenkins



 I could open the Jenkins dashboard at port 8090 but on the dashboard it
 showed Jenkins is offline. I entered bash of this container:

 docker exec -it –user root  bash

 and tried to restart it:

 service jenkins restart

 The output was it cannot find the command jenkins.



 Two questions:

 1.   Why is this offline and how to bring it online?

 2.   Is containerized Jenkins different from Linux Jenkins? Why I
 cannot use normal jenkins command like restart/start/stop/status?



 Thanks a lot,

 Huan





 --
 You received this message because you are subscribed to the Google
 Groups "Jenkins Developers" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to jenkinsci-de...@googlegroups.com.
 To view this discussion on the web visit https://groups.google.com/d/ms
 gid/jenkinsci-dev/MWHPR03MB26051CF398DB445BFE2F4E84B4F60%
 40MWHPR03MB2605.namprd03.prod.outlook.com
 
 .
 For more options, visit https://groups.google.com/d/optout.

>>>
>>>
>>

-- 
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/CANWgJS473xBpT2LcCpx9zJnyaEQx8X_mjNRTEi4sQ5iF2y6qoA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Jenkins in container is offline

2016-09-21 Thread Hung Suen
I posted the topic to Jenkins developers. Should have posted it here.
https://groups.google.com/d/topic/jenkinsci-dev/LCPjMbKCmGM/discussion

-- 
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/b3c1a12a-f2f7-44ab-9227-9546cd228853%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Compiling Jenkins from source

2016-09-21 Thread Radcliff, Allen
Fantasticthank you every much!!

Allen

On Wed, Sep 21, 2016 at 3:44 PM, Baptiste Mathus  wrote:

> Hello,
>
> This is because this is a tag. "jenkins-1.658".
>
> Cheers
>
> 2016-09-21 21:38 GMT+02:00 Radcliff, Allen :
>
>> Greetings!
>>
>> I have Jenkins 1.658 installed on a CentOS 6.6 server.  We are undergoing
>> an accreditation process which requires me to compile external software
>> from source.  After cloning the source repo:
>>
>> *git clone https://github.com/jenkinsci/jenkins.git 
>> *
>>
>> I run a "*git branch -r*", but do not see a branch for version 1.658.
>> Please advise.
>>
>> Thank you!
>>
>> Allen
>>
>> --
>> 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/ms
>> gid/jenkinsci-users/CALcD%3DCECVmDdydjmPi3qoyd3Wf%3DRxo%2BTm
>> YOtmQE5DKTqNX8t-A%40mail.gmail.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> 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/CANWgJS6_Per_9%3DE58fRLD44uSJ-
> dn0oFEvqD%3DgKP6GXzVBYkWg%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CALcD%3DCFq2c6a-wEj%2BvkXH%3DFa4atapuahpWtXA5UzRCqcVN5pBw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: snipped generator for xunit google test

2016-09-21 Thread Klaus Rudolph



Am 12.09.2016 um 22:36 schrieb Liam Newman:

First make sure you have the latest version of the xUnit plugin installed.
Then, try looking under "step: General Build Step" and under "Build Step"
see "Process xUnit test result report".


Success :-)

Thanks!

Klaus

--
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/fef24b77-7cb3-c111-a844-45f30e05f5dd%40gmx.de.
For more options, visit https://groups.google.com/d/optout.


Re: Compiling Jenkins from source

2016-09-21 Thread Baptiste Mathus
Hello,

This is because this is a tag. "jenkins-1.658".

Cheers

2016-09-21 21:38 GMT+02:00 Radcliff, Allen :

> Greetings!
>
> I have Jenkins 1.658 installed on a CentOS 6.6 server.  We are undergoing
> an accreditation process which requires me to compile external software
> from source.  After cloning the source repo:
>
> *git clone https://github.com/jenkinsci/jenkins.git 
> *
>
> I run a "*git branch -r*", but do not see a branch for version 1.658.
> Please advise.
>
> Thank you!
>
> Allen
>
> --
> 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/CALcD%3DCECVmDdydjmPi3qoyd3Wf%3DRxo%
> 2BTmYOtmQE5DKTqNX8t-A%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CANWgJS6_Per_9%3DE58fRLD44uSJ-dn0oFEvqD%3DgKP6GXzVBYkWg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Compiling Jenkins from source

2016-09-21 Thread Radcliff, Allen
Greetings!

I have Jenkins 1.658 installed on a CentOS 6.6 server.  We are undergoing
an accreditation process which requires me to compile external software
from source.  After cloning the source repo:

*git clone https://github.com/jenkinsci/jenkins.git
*

I run a "*git branch -r*", but do not see a branch for version 1.658.
Please advise.

Thank you!

Allen

-- 
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/CALcD%3DCECVmDdydjmPi3qoyd3Wf%3DRxo%2BTmYOtmQE5DKTqNX8t-A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


locks vs stage w/concurrency

2016-09-21 Thread David Karlsen
I have a question on locks vs stage w/ concurrency:

lock(inversePrecedence: true, resource: 'myLock') {
// some block
}

vs
stage(name:'myStage',concurrency:1) {
// some block
}


With stages newer builds would "win" over older ones while waiting to run
so that unnecessary was avoided, however with locks all builds will run - I
want the newer job to wait for a lock to win, and the ones that became
stale to disappear - this does not seem possible?


-- 
--
David J. M. Karlsen - http://www.linkedin.com/in/davidkarlsen

-- 
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/CAGO7Ob0AXiyyZqea7KNLWPJO7dyXO8H6KGmymqrwp__M7Ngdzw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Build Machine Migration Issues

2016-09-21 Thread Eric Fetzer
I moved to a new build machine and migrated the Jenkins repository.  
Everything looks ok, but won't build.  First issues I'm seeing seem to have 
to do with java and antcontrib.  Anyone know how I resolve the following 
errors?

Unable to locate tools.jar. Expected to find it in 
/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.101-3.b13.el6_8.x86_64/lib/tools.jar

Buildfile: /opt/jenkins/workspace/NAP-Client/build.xml
  [taskdef] Could not load definitions from resource 
net/sf/antcontrib/antcontrib.properties. It could not be found.
  [taskdef] Could not load definitions from resource 
net/sf/antcontrib/antcontrib.properties. It could not be found.
  [taskdef] Could not load definitions from resource flexTasks.tasks. It could 
not be found.
  [taskdef] Could not load definitions from resource flexUnitTasks.tasks. It 
could not be found.
  [taskdef] Could not load definitions from resource 
net/sf/antcontrib/antlib.xml. It could not be found.


Thanks,

Eric

-- 
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/cbdd40e7-5e3c-4056-ba86-4432bec7938a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins EMail Reporting

2016-09-21 Thread jerome
I known my answer will not be received well by most, but that was the 
fastest way I could find, I did a Python script with XunitParser module 
made that a breeze (I can even test it better or use other tools to run 
them).

https://pypi.python.org/pypi/xunitparser

Just write to a temporary file using the tmp() folder and then sh or bat 
the python script and give the output file as argument, output into the 
wanted format and just read the file into Jenkins pipeline.

All those little Python script have save me hours so far compare to messing 
around into the Jenkins "cripple" Groovy. Just doing a iteration on list 
doesn't work as it is suppose too into that Groovy implementation! @NonCPS 
is a bag of crab so far for me (same function does or doesn't return the 
same result with or without the @NonCPS, some function I had written where 
working until some update where I had to add the @NonCPS by updating 
Jenkins). Having to allow all the operations (map hash, file 
getAbsolutePath, operator string to string, ...) but can launch a shell or 
batch operation that can access whatever folder.

May sound harsh on Jenkins, but every new commer have question on how to do 
simple stuff (this include myself, I'm no different here! the struggle is 
real, especially for people who did not touch any groovy before and realize 
they don't really have a full features Groovy engine to play with) because 
we can't rely on Groovy way of doing those thing, because those way doesn't 
work most of the time into that implementation or need to be tweak a lots 
to make them working. Many of those questions are left without answer since 
nobody really know how to do them properly into that script engine.


-- 
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/124ae7d3-2a6e-431e-b8e0-d682dcf64303%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Server ssh errors on pipeline jobs

2016-09-21 Thread gary . hooper
so my problem has been solved.  the issue ended up being a malformed PATH 
setting in the Mac node configuration.  however, due to a bug in Jenkins, 
that setting was never active, thus the builds were working fine, until a 
Jenkins restart for an unrelated issue caused this malformed PATH 
definition to take effect and break the build.

thanks for the ideas to solve.  using GET_SSH_COMMAND led to the real 
problem and solution.



On Tuesday, September 20, 2016 at 5:52:17 PM UTC-7, Mark Waite wrote:
>
> Some of the possible investigations to perform:
>
>- If the URL you're using is an ssh style or an scp style URL, then 
>you need to check that your private key authentication from the Jenkins 
>agent to the git server are functioning
>- If using ssh, you might try the instructions at 
>
> http://askubuntu.com/questions/336907/really-verbose-way-to-test-git-connection-over-ssh
>  to 
>diagnose git connections over ssh
>- If the URL you're using is an http or https URL, then check that 
>your user name and password are working from the Jenkins agent to the git 
>server
>- Read the log files on the git server to see if they provide hints of 
>the cause of the failures
>
>
> Mark Waite
>
> On Tue, Sep 20, 2016 at 6:43 PM Gary Hooper  > wrote:
>
>> It's happening with both 3.0.0 and 2.4.4.  (We just upgraded to 3.0.0 to 
>> see if that would help; alas, it did not.)
>>
>> --gary
>>
>> On 9/20/16 17:29, Mark Waite wrote:
>>
>> Did your Jenkins server recently upgrade to git plugin 3.0.0?  There has 
>> been at least one report of authentication issues on a Mac running git 
>> plugin 3.0.0. 
>>
>> If so, then you might check if a revert of the upgrade to git plugin 
>> 3.0.0 resolves the issue.
>>
>> Mark Waite
>>
>> On Tue, Sep 20, 2016 at 5:29 PM < gary@avegant.com 
>> > wrote:
>>
>>> I am seeing the exact same problem.  It just started happening out of 
>>> the blue, no known changes to Jenkins or builder node (which is a Mac).
>>>
>>> Ion, did you resolve it?
>>>
>>> --gary
>>>
>>>
>>> On Wednesday, June 29, 2016 at 12:48:36 PM UTC-7, Ion Roșca wrote: 

 Hi All, 

 I managed to implement the build infrastructure using Jenkin 
 multibranch and simple pipelines. Today I suddenly started getting errors 
 for all the jobs involving pipelines - simple pipeline jobs or jobs 
 created 
 via multibranch plugin. The errors happen on Jenkins server before any of 
 the pipeline code gets chance to be executed. I cleared up the workspace 
 from Jenkins server, job logs - nothing helped.
 If I clone the failing job using a different job name, or if I delete 
 the failing job and create a new one from scratch with the same name and 
 settings - the new job still fails.
 If I create a brand new job with a new name and the same settings - the 
 job starts working. This means that the access to git via ssh works, and 
 it 
 leads me to thinking about some bugs on the server side.

 Do you have any ideas why is this error happening and how can I fix it?
 The build log is below.

 Thank you,
 Ion.

 Started by user anonymous 
 Connecting 
 to https://git.corp.rosca.com/api/v3/  
 using */**
  > git rev-parse --is-inside-work-tree # timeout=10Fetching changes from 2 
 remote Git repositories
  > git config remote.origin.url git@git.*.com:Org/project.git # 
 timeout=10Fetching upstream changes from 
 g...@git.corp.rosca.com:Org/project.git
  > git --version # timeout=10using GIT_SSH to set credentials 
  > git -c core.askpass=true fetch --tags --progress 
 g...@git.corp.rosca.com:Org/project.git +refs/heads/*:refs/remotes/origin/*
 ERROR: Error fetching remote repo 'origin'hudson.plugins.git.GitException 
 :
  Failed to fetch from g...@git.corp.rosca.com:Org/project.git 
 at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:792) 
 
 at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1048) 
 
 at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1079) 
 
 at 
 org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:109)
  
 
 at 
 org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:108)
  

Re: The new Global Pipeline Library

2016-09-21 Thread Michael Lasevich
I am making an assumption that "Modern SCM" is some new Jenkins SCM API not 
yet supported by most common SCMs - so I am just ignoring it and using 
Legacv SCM

As for ${library.name.version} - you use it if you specify branch/tag in 
GIT or in URL for SVN

Basically when you load the library with @Library syntax, you can (if 
enabled) specify a version (release, beta, v2, whatever you want to call 
it). When SCM fetches it, it needs to know what to do with this "version" 
you specified. So, for SVN you include ${library.name.version} in your SVN 
URL in global library config, so when it checks it out, it will check out 
the version specified in your @Library statement. Similarly for git, which 
has a fixed URL for all branches, you specify fixed URL but use the version 
variable in your branch specifier (which can point to either a branch or a 
tag) 

So for example for my "testlib" library, my branch specifier is : 
'refs/heads/release/${library.testlib.version}'

So when I do '@Library "testlib@beta" _' in my code, I get branch 
release/beta

Here is a tiny trick I do here, btw --  notice that I hardcode the 
"release/" prefix to my branch - I do this to prevent the scripts from 
specifying any branch other than the one with 'release/' prefix - this 
prevents developers working on new features from being able to load those 
features into Jenkins (which for global libs runs outside the sandbox) 
without a proper peer review (release/*" branches are restricted in my 
config).

HTH,

-M




On Monday, September 12, 2016 at 12:48:02 AM UTC-7, Sverre Moe wrote:
>
> There has been changes in the Global Pipeline Library plugin
> https://issues.jenkins-ci.org/browse/JENKINS-31155
>
> Jenkins Configuration => Global Pipeline Libraries
> Choosing "Modern SCM" the next drop down list is empty. What does this 
> option actually do?
> Choosing "Legacy SCM" I'm able to define a git repository for the library.
>
>
> 
>
>
> 
>
>
>
>
> According to the documentation:
>
>> It can be used in two modes: a legacy mode in which there is a single Git 
>> repository hosted by Jenkins itself, to which you may push changes; and a 
>> more general mode in which you may define libraries hosted by any SCM in a 
>> location of your choice.
>
>
> Should it not be the other way around for the modes in configuration? 
> Modern SCM should have option to add SCM.
>
>
>
> The best way to specify the SCM is using an SCM plugin which has been 
>> specifically updated to support a new API for checking out an arbitrary 
>> named version (Modern SCM option). Initially the Git and Subversion plugins 
>> have this modification
>
> Choosing Modern SCM there is no option in the drop down list. Neither git 
> nor subversion. Though they are with Legacy SCM.
>
>
>
> If your SCM plugin has not been integrated, you may select Legacy SCM and 
>> pick anything offered. In this case, you need to include 
>> ${library.yourLibName.version} somewhere in the configuration of the SCM, 
>> so that during checkout the plugin will expand this variable to select the 
>> desired version.
>
> For a library in a git repository would I need to tag a specific version?
>
>
> ---
>
>
> It is great that we now can use a shared library stored with our own Git 
> remote repository server. However until we transition to that have 
> workflowLibs.git work as before.
>
>
> If I move the shared library to a different SCM I would probably need to 
> remove workflowLibs.git otherwise how would Jenkins know which one to load 
> as I need to load it implicitly.
>

-- 
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/3055d52a-078d-4c25-8f32-b0241e5b7d71%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Help with Config File Provider Plugin in Pipeline

2016-09-21 Thread Taylor Patton
Hi,


I’m trying to use the Config File Provider Plugin in my Pipeline build but
its not working. Following the very basic example from the wiki page:


configFileProvider(

[configFile(fileId: ‘my-custom-file-id', variable:
'MAVEN_SETTINGS')]) {

sh 'mvn -s $MAVEN_SETTINGS clean package'

}


Results in this error:


groovy.lang.MissingPropertyException: No such property: MAVEN_SETTINGS for
class: groovy.lang.Binding

at groovy.lang.Binding.getVariable(Binding.java:63)



I can see that the file is indeed copied into my workspace, but I’m not
able to use the file with “mvn -s $MAVEN_SETTINGS”:


I am able to view the contents of the file like this, however:

sh 'cat $MAVEN_SETTINGS’


Please advise,


-Taylor

-- 
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/CAMvOKWTt98fRi19-ieg5wTU0AD5F3BaPqqaa1BobmdqKro6VjA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Loading properties from a file in Jenkins 2.0 pipeline

2016-09-21 Thread Phillip Campbell
Here's a snippet from a Jenkinsfile in a pre-2.0  pipeline job that I use
to read an existing build.properties file in the workspace so that the
Jenkinsfile can use the properties.  I haven't tried this in 2.0 pipeline
yet.

if (!fileExists('build.properties')){echo 'No
build properties.'  exit }def props =
readProperties file: 'build.properties' /*   * From build.properties
file */def Var1= props["SOME_PROPERTY"]def Var2=
props["ANOTHER_PROPERTY"]


On Wed, Sep 21, 2016 at 8:22 AM, Pete Singleton 
wrote:

> Hi, I'm having exactly the same issue (having only started with Jenkins
> 2.0 in the last couple of days).  I've tried the Pipeline Utility, tried
> the EnvInject plugin, also tried opening the file using Groovy file
> operations, no success!  Did you manage to solve this??
>
> On Thursday, 8 September 2016 21:50:01 UTC+1, Ian Cotton wrote:
>>
>> Thanks Jerome. Unfortunately this doesn't help me much. The properties
>> file I need to load already exists and is in use by various build scripts.
>> I assume I need to create an EnvInjectJobProperty object and set the
>> appropriate property on it. I'll give that a try.
>>
>> On Wed, Sep 7, 2016 at 7:07 PM  wrote:
>>
>>> Not sure about the Java properties file, but I succeed by doing a
>>> .groovy file if that's interest you (probably not, but here it is if
>>> someone need it, it's unsafe but in controlled env it doesn't matter):
>>>
>>> *Jenkinsfile*
>>> def my_var = evaluate(new File("myEnv.groovy"));
>>> bat "\"${my_var.python_2_exe}\" myscript.py"
>>> ...
>>>
>>> *myEnv.groovy*
>>> def rv= [:]
>>>
>>> rv['mercurial_url'] = 'http://mercurial.buildserver/'
>>> rv['python_2_exe'] = "c:\\Python27\\python.exe"
>>> ...
>>> return rv;
>>>
>>> I put the .groovy file on the build machine jenkins folder, so the
>>> Jenkinsfile from the repos can work with vars from any of our build
>>> machines or network emplacement.
>>>
>>> --
>>> 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-use...@googlegroups.com.
>>> To view this discussion on the web visit https://groups.google.com/d/ms
>>> gid/jenkinsci-users/1a03bb2f-5022-4005-ab10-5e3146aebcd1%
>>> 40googlegroups.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
> 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/fcf3de22-08c3-47e2-b996-1d0bd85f28ed%40googlegroups.
> com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CAAYHPVij13azLVN%2BwkQfeGG_ExE6eUqGE1A4cL9Dg-zvwtXK0A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Jenkins EMail Reporting

2016-09-21 Thread Bubunia Patra
Hi all,

I am looking for some way to email the test results from the Jenkins to the 
recipients in a nice format After my test executes the console logs are 
generated in jenkins. I have installed the extended E-mail Plugin for email 
and configured the smtp server. The test also generates the JUNIT.xml which 
contains Pass/Fail results but doesn't contain the failure reason which 
needs to be retrieved from the console logs.

The Email-Plugin emails the results but it is either truncated or not the 
format I want it. Is there any other plugin I need to use which will 
retrieve the failure reason from the console log and email the results 
similar to below:

I want Something like the below in a table  :

TestCase Name |  Status |  Link |  Failure Reason
==

Is there a better way or example for Email reporting in Jenkins to suffice 
my requirement? If so what are the other tools/plugins I should install and 
the way I can achieve this? I saw the customise email reporting can be 
achieved through jelly script. Can someone provide me an example jelly 
script for email reporting ?

https://wiki.jenkins-ci.org/display/JENKINS/Email-ext+plugin#Email-extplugin-Advancedconfiguration

I will appreciate if some one can help me in this regard?

Regards
Pradeep

-- 
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/9a902866-2bc9-44fe-86fa-5e63d5852552%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Loading properties from a file in Jenkins 2.0 pipeline

2016-09-21 Thread Pete Singleton
Hi, I'm having exactly the same issue (having only started with Jenkins 2.0 
in the last couple of days).  I've tried the Pipeline Utility, tried the 
EnvInject plugin, also tried opening the file using Groovy file operations, 
no success!  Did you manage to solve this??

On Thursday, 8 September 2016 21:50:01 UTC+1, Ian Cotton wrote:
>
> Thanks Jerome. Unfortunately this doesn't help me much. The properties 
> file I need to load already exists and is in use by various build scripts.
> I assume I need to create an EnvInjectJobProperty object and set the 
> appropriate property on it. I'll give that a try.
>
> On Wed, Sep 7, 2016 at 7:07 PM  wrote:
>
>> Not sure about the Java properties file, but I succeed by doing a .groovy 
>> file if that's interest you (probably not, but here it is if someone need 
>> it, it's unsafe but in controlled env it doesn't matter):
>>
>> *Jenkinsfile*
>> def my_var = evaluate(new File("myEnv.groovy"));
>> bat "\"${my_var.python_2_exe}\" myscript.py"
>> ...
>>
>> *myEnv.groovy*
>> def rv= [:]
>>
>> rv['mercurial_url'] = 'http://mercurial.buildserver/'
>> rv['python_2_exe'] = "c:\\Python27\\python.exe"
>> ...
>> return rv;
>>
>> I put the .groovy file on the build machine jenkins folder, so the 
>> Jenkinsfile from the repos can work with vars from any of our build 
>> machines or network emplacement. 
>>
>> -- 
>> 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-use...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/1a03bb2f-5022-4005-ab10-5e3146aebcd1%40googlegroups.com
>>  
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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/fcf3de22-08c3-47e2-b996-1d0bd85f28ed%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: The new Global Pipeline Library

2016-09-21 Thread Tim Downey
Hellojust giving this thread a bump as I'm having the same questions. 
 What exactly is supposed to be the configuration for Modern SCM?  I have 
been able to get it to work using the Legacy SCM to point at my git repo.

On Monday, September 12, 2016 at 3:48:02 AM UTC-4, Sverre Moe wrote:
>
> There has been changes in the Global Pipeline Library plugin
> https://issues.jenkins-ci.org/browse/JENKINS-31155
>
> Jenkins Configuration => Global Pipeline Libraries
> Choosing "Modern SCM" the next drop down list is empty. What does this 
> option actually do?
> Choosing "Legacy SCM" I'm able to define a git repository for the library.
>
>
> 
>
>
> 
>
>
>
>
> According to the documentation:
>
>> It can be used in two modes: a legacy mode in which there is a single Git 
>> repository hosted by Jenkins itself, to which you may push changes; and a 
>> more general mode in which you may define libraries hosted by any SCM in a 
>> location of your choice.
>
>
> Should it not be the other way around for the modes in configuration? 
> Modern SCM should have option to add SCM.
>
>
>
> The best way to specify the SCM is using an SCM plugin which has been 
>> specifically updated to support a new API for checking out an arbitrary 
>> named version (Modern SCM option). Initially the Git and Subversion plugins 
>> have this modification
>
> Choosing Modern SCM there is no option in the drop down list. Neither git 
> nor subversion. Though they are with Legacy SCM.
>
>
>
> If your SCM plugin has not been integrated, you may select Legacy SCM and 
>> pick anything offered. In this case, you need to include 
>> ${library.yourLibName.version} somewhere in the configuration of the SCM, 
>> so that during checkout the plugin will expand this variable to select the 
>> desired version.
>
> For a library in a git repository would I need to tag a specific version?
>
>
> ---
>
>
> It is great that we now can use a shared library stored with our own Git 
> remote repository server. However until we transition to that have 
> workflowLibs.git work as before.
>
>
> If I move the shared library to a different SCM I would probably need to 
> remove workflowLibs.git otherwise how would Jenkins know which one to load 
> as I need to load it implicitly.
>

-- 
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/0b43e653-335d-4f82-94d2-366c9fb6a214%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


"Restrict where this project can be run" option not found on Multi branch pipeline jobs; Same option is found in freestyle jobs in jenkins 2.7.4

2016-09-21 Thread Grit90
Hey Guys,

I've recently upgraded our primary jenkins, from 1.642.2 to 2.7.4 and 
facing the above issue.

I've read into some forums online where they are asking me to install 
nodelabel plugin; I believe that may not be it as it is available for "free 
style" jobs.

Is there a way for me to get this working? May be using JenkinsFile?

-- 
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/4d27b7cb-7ff7-4f7a-a1a5-6b585abb5260%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Avoid simultaneous job modifications in Jenkins

2016-09-21 Thread Stephen Connolly
Not currently... it would be great if core provided a mechanism to
assist... even an alert that somebody else is in the config screen and
making changes... or better yet that somebody has saved changes...

But not currently available in core.

On 21 September 2016 at 12:20, Angel Yanev  wrote:

> I am using the Jenkins Job DSL Plugin to create template jobs.
>
> There is a problem when two or more users are modifying the same template
> job (or any other job) simultaneously. The configuration of the last user
> to save or apply the modifications are registered and the modifications of
> the other user are removed because the two users were working on the same
> configuration version.
>
> For example: Recently, I had to add a user to the global authorization
> matrix in a template job. I did that and i saved and build it. However,
> another user was modifying the same template job all day and he saved it at
> the end of the day and my changes were removed.
>
> Is there a way to avoid this simultaneous job modifications by locking the
> configuration of a job for other users when that user is currently updating
> it?
>
> --
> 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/f8d61777-e02f-4d77-893e-30e143685c76%40googlegroups.
> com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CA%2BnPnMyfy-jitmTcsnuEfzD_qX0BvxwDCwoti%2BAFsaS5dcexDQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


package jenkins.war including custom plugins from github

2016-09-21 Thread Siva Kumar Reddy G


I am trying to package Jenkins with customization. Customization here means 
including few plugins as part of Jenkins.war. I am able to add Jenkins 
provided plugins successfully. The build is successful and war file 
created. 


Added Jenkins.war to web apps folder of tomcat. Started Tomcat and browsed 
localhost. Selected "Install suggested plugins". I get error saying: *An 
error occurred during installation: No such plugin: custom-plugin*


Please help. Thanks in advance.

-- 
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/bb8392b3-cfbc-4ee8-b481-fc6a2c6d957f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


RE: Standalone mirrored update site without signature checking

2016-09-21 Thread Jason Pyeron
> -Original Message-
> From: Bilsby David C
> Sent: Wednesday, September 21, 2016 05:17
> 
> OK I think I have fixed this myself. To disable signature 
> checking on the update file you need to set the 
> hudson.model.DownloadService.signatureCheck variable to 
> false. I did this through a groovy script added to the 
> %JENKINS_HOME%\init.groovy.d directory. The script I used 
> contained the following:
> 
> import jenkins.model.*
> 
> try
> {
>   hudson.model.DownloadService.signatureCheck=false;
>   println(“Disabled signature checking for update service.”);
> }
> catch (MissingPropertyException e)
> {
>   println(“No signature check disable property found!”);
> }

Thanks, this will help us too. Ideally, we would prefere to re-sign and leave 
the signature checking in place. Does anyone have ideas as to that?

-- 
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/DE43F284DA14403E8528CF9526FB3BD1%40black7.
For more options, visit https://groups.google.com/d/optout.


Avoid simultaneous job modifications in Jenkins

2016-09-21 Thread Angel Yanev
 

I am using the Jenkins Job DSL Plugin to create template jobs. 

There is a problem when two or more users are modifying the same template 
job (or any other job) simultaneously. The configuration of the last user 
to save or apply the modifications are registered and the modifications of 
the other user are removed because the two users were working on the same 
configuration version.

For example: Recently, I had to add a user to the global authorization 
matrix in a template job. I did that and i saved and build it. However, 
another user was modifying the same template job all day and he saved it at 
the end of the day and my changes were removed.

Is there a way to avoid this simultaneous job modifications by locking the 
configuration of a job for other users when that user is currently updating 
it?

-- 
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/f8d61777-e02f-4d77-893e-30e143685c76%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


How do you use the DTKit plugin?

2016-09-21 Thread Bilsby David C
I'm trying to find a way to publish code metrics generated by Parasoft C++test. 
The Parasoft Jenkins plugin does not seem to publish the metrics, only static 
analysis and unit tests. I stumbled across the DTKit plugin which seemed 
mentioned Parasoft in its change log, and the description sounded like it may 
be possible to use this to convert the metrics XML file into something which 
could be published in Jenkins.

However I cannot figure out how to use the DTKit plugin. What do you do with 
it? Does it add itself as a build or post-build step?

I'm running Jenkins 2.18 on Windows 7 64-bit.

Thanks

This email and any attachments to it may be confidential and are
intended solely for the use of the individual to whom it is 
addressed. If you are not the intended recipient of this email,
you must neither take any action based upon its contents, nor 
copy or show it to anyone. Please contact the sender if you 
believe you have received this email in error. QinetiQ may 
monitor email traffic data and also the content of email for 
the purposes of security. QinetiQ Limited (Registered in England
& Wales: Company Number: 3796233) Registered office: Cody Technology 
Park, Ively Road, Farnborough, Hampshire, GU14 0LX  http://www.qinetiq.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/57e25133.15691c0a.a40ff.1970SMTPIN_ADDED_MISSING%40gmr-mx.google.com.
For more options, visit https://groups.google.com/d/optout.


RE: Standalone mirrored update site without signature checking

2016-09-21 Thread Bilsby David C
OK I think I have fixed this myself. To disable signature checking on the 
update file you need to set the hudson.model.DownloadService.signatureCheck 
variable to false. I did this through a groovy script added to the 
%JENKINS_HOME%\init.groovy.d directory. The script I used contained the 
following:

import jenkins.model.*
try
{
  hudson.model.DownloadService.signatureCheck=false;
  println(“Disabled signature checking for update service.”);
}
catch (MissingPropertyException e)
{
  println(“No signature check disable property found!”);
}


--
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/57d040ca.c2111c0a.8061b.4bf3SMTPIN_ADDED_MISSING%40gmr-mx.google.com.
For more options, visit https://groups.google.com/d/optout.

This email and any attachments to it may be confidential and are
intended solely for the use of the individual to whom it is 
addressed. If you are not the intended recipient of this email,
you must neither take any action based upon its contents, nor 
copy or show it to anyone. Please contact the sender if you 
believe you have received this email in error. QinetiQ may 
monitor email traffic data and also the content of email for 
the purposes of security. QinetiQ Limited (Registered in England
& Wales: Company Number: 3796233) Registered office: Cody Technology 
Park, Ively Road, Farnborough, Hampshire, GU14 0LX  http://www.qinetiq.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/57e25004.06e11c0a.40e7d.342cSMTPIN_ADDED_MISSING%40gmr-mx.google.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins on Websphere 8.5 - out of memory (heap)

2016-09-21 Thread Tomáš Mrázek
300kb is not much, but if you look at the implementation of the called 
method 
https://github.com/kohsuke/winp/blob/master/src/main/java/org/jvnet/winp/WinProcess.java
 
,I got heap exception at line 144. The method creates substrings in loop 
string lenght > 0. So theoretically after each iteration it stores to RAM 
another string with one character less.

-- 
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/0c2d5194-6237-4619-b780-648f0abc8a23%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Maintaining a unique Build Number across multiple build servers

2016-09-21 Thread Michael Neale
Not sure if it may help solve a similar aim - 
but https://wiki.jenkins-ci.org/display/JENKINS/Version+Number+Plugin 
exists (might be others)

On Wednesday, September 21, 2016 at 1:47:03 PM UTC+10, Cuong Tran wrote:
>
> It doesn't exist.
>
> On Monday, September 19, 2016 at 12:54:15 PM UTC-7, Robert Kruck wrote:
>>
>>  Is it possible to preserve the integrity of build numbers (NO 
>> DUPLICATES and build numbers in order) while building in multiple Jenkins 
>> build servers?
>>
>> If this capability exists in Jenkins, what Jenkins plugins are required, 
>> and what versions of Jenkins itself, and of the required Jenkins plugins, 
>> are needed?
>>
>

-- 
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/8eaebd9a-23c2-483e-a752-c64f48334944%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: terminate pipeline parallal on first failure

2016-09-21 Thread Michael Neale
There is also: https://jenkins.io/doc/pipeline/

but generally for the steps - if you open a job to edit, you should see 
either near the pipeline text area or on the left a "Pipeline Syntax" link 
you can open in a new tab. It gives you a choice of steps that will build 
the syntax out for you as things you can copy and paste.

On Wednesday, September 21, 2016 at 1:42:40 PM UTC+10, Cuong Tran wrote:
>
> The reference link is right on any pipeline job.  You should see a 
> "Pipeline Syntax" link, click on that will give a list of known steps, the 
> click on the question icon will give you an example.
>
>
> On Tuesday, September 20, 2016 at 1:57:43 PM UTC-7, asmundo wrote:
>>
>> Thank you Baptiste!
>>
>> Tested and it worked. You owe you a beer! 
>>
>> I am new to pipeline programming. I worked several hours today on this 
>> and other pipeline related work. Could you please point me to the 
>> documentation of this syntax? I must have been looking in the wrong 
>> location. 
>>
>> Cheers
>>
>>
>>
>> On Tue, Sep 20, 2016 at 10:47 PM, Baptiste Mathus  
>> wrote:
>>
>>> Hi,
>>>
>>>  stage('tests') {
>>> parallel 'longTests': {
>>> build job: 'testjob1', quietPeriod: 0
>>> }, 'shortTests':{
>>> // this will fail 1 sec
>>> build job: 'testjob2', quietPeriod: 0
>>> }, failFast: true   
>>>
>>> }
>>>
>>> Cheers
>>>
>>> 2016-09-20 22:43 GMT+02:00 Åsmund Østvold :
>>>
 hi All,

 Do anybody have an example or a pointer to how one could terminate a 
 parallel pipeline section on first failure?

 The use case is that I have 14 tests in a checkin regression pipeline. 
 Some tests take 2 min some take 40 min. To speed up feedback to the users 
 we want to give feed back ASAP if a test did fail. 

 My test pipeline is:

 stage('tests') {
 parallel 'longTests': {
 build job: 'testjob1', quietPeriod: 0
 }, 'shortTests':{
 // this will fail 1 sec
 build job: 'testjob2', quietPeriod: 0
 }
 }

 My current "pipeline" (Build-flow) is able to do this with a ugly hack:

 import static hudson.model.Result.FAILURE
 import groovy.time.*

 parallel (
   { b = build("testjob1")
 if (b.getResult().toString() != "SUCCESS") {
 upstream.getExecutor().interrupt(FAILURE)
}
   },
   { b = build("testjob2"])
 if (b.getResult().toString() != "SUCCESS") {
 upstream.getExecutor().interrupt(FAILURE)
}
   }
 )

 Regard,
 Asmund

 -- 
 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-use...@googlegroups.com.
 To view this discussion on the web visit 
 https://groups.google.com/d/msgid/jenkinsci-users/CA%2BzfM3Bq0x7djYpWaXfvSbHrFf2DuGJeZ8fEsVskT%3DDfTeKq2w%40mail.gmail.com
  
 
 .
 For more options, visit https://groups.google.com/d/optout.

>>>
>>> -- 
>>> 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-use...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/CANWgJS76kD0W0dTTPeF3P0xXtC1UomAHJ6Swtbog68%3DPDSWyPQ%40mail.gmail.com
>>>  
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>

-- 
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/56293faf-3380-4601-ab74-ccf8710f4c56%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.