Re: One github repo, two pipelines, two distinct checks in github?

2017-09-18 Thread 'Ian Smith' via Jenkins Users
Hi Richard,

Thank you for that suggestion. Checked that we did have those plugins 
installed and then came across withCredentials in the pipeline syntax. 
After adding that I'm now able to pull out the access token from the 
Jenkins credentials without it appearing in plain text.

Regarding the second point, I think this just how Github works 
unfortunately, and comes back to the assumed 1:1 mapping. To be fair there 
is no real way that github can know the infrastructure on a remote Jenkins 
site to know that a commit could have multiple replies. In an ideal world 
it would be nice if the pr_merge did a logic AND to any replies it sees, 
but I can see that this could cause other issues. By using the status API 
at least it is possible for each pipeline to indicate it's own individual 
status.

Ian

On Friday, September 15, 2017 at 11:08:58 PM UTC+1, Richard Bywater wrote:
>
> With regards to 1, the credentials and credential binding plugins would 
> probably help out there as you wouldn't have to embed the token in the 
> script.
>
> Can't comment on the other issues though. 
>
> Richard 
>
> On Sat, 16 Sep 2017, 3:01 AM 'Ian Smith' via Jenkins Users <
> jenkins...@googlegroups.com > wrote:
>
>> Hi Ann,
>>
>> Thank you for that information. Sadly this isn't a viable option due to 
>> two reasons
>>
>>1. Having to embed the Github user token in the curl command, which 
>>means adding that to the Jenkinsfile script
>>2. The webhook still takes the value of the build state for the last 
>>pipeline. So although I can define separate values and I see three check 
>>marks in the PR in github, if the second pipeline marks the build as a 
>>failure then the pr-merge status is also set to failure.
>>
>> Kind regards, Ian
>>
>> On Saturday, September 9, 2017 at 6:18:36 AM UTC+1, Ann B wrote:
>>>
>>> Hi Ian-
>>>
>>> I'm sorry that I cannot answer your question directly, as we do not use 
>>> a web hook.
>>>
>>> Have you thought of posting to the github statuses api - 
>>> https://developer.github.com/v3/repos/statuses/#create-a-status with a 
>>> separate link for each of your pipelines?   We kick off all of our pipeline 
>>> jobs in parallel (static, functional, unit, etc).  Each job adds a Statuses 
>>> link to the PR with an initial value of 'Pending' with a link to the 
>>> running job in jenkins.  As each parallel job finishes, it updates the PR 
>>> Status with 'Failed' or 'Passes'.
>>>
>>> Ann
>>>
>> -- 
>> 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/a662c5ae-5c92-40ac-9169-9446477d9f60%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/9811cf61-16d7-4e3e-801d-82aec87e27bc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: One github repo, two pipelines, two distinct checks in github?

2017-09-15 Thread Richard Bywater
With regards to 1, the credentials and credential binding plugins would
probably help out there as you wouldn't have to embed the token in the
script.

Can't comment on the other issues though.

Richard

On Sat, 16 Sep 2017, 3:01 AM 'Ian Smith' via Jenkins Users <
jenkinsci-users@googlegroups.com> wrote:

> Hi Ann,
>
> Thank you for that information. Sadly this isn't a viable option due to
> two reasons
>
>1. Having to embed the Github user token in the curl command, which
>means adding that to the Jenkinsfile script
>2. The webhook still takes the value of the build state for the last
>pipeline. So although I can define separate values and I see three check
>marks in the PR in github, if the second pipeline marks the build as a
>failure then the pr-merge status is also set to failure.
>
> Kind regards, Ian
>
> On Saturday, September 9, 2017 at 6:18:36 AM UTC+1, Ann B wrote:
>>
>> Hi Ian-
>>
>> I'm sorry that I cannot answer your question directly, as we do not use a
>> web hook.
>>
>> Have you thought of posting to the github statuses api -
>> https://developer.github.com/v3/repos/statuses/#create-a-status with a
>> separate link for each of your pipelines?   We kick off all of our pipeline
>> jobs in parallel (static, functional, unit, etc).  Each job adds a Statuses
>> link to the PR with an initial value of 'Pending' with a link to the
>> running job in jenkins.  As each parallel job finishes, it updates the PR
>> Status with 'Failed' or 'Passes'.
>>
>> Ann
>>
> --
> 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/a662c5ae-5c92-40ac-9169-9446477d9f60%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/CAMui947Qw6jd5A61vbEWwQ5wTRUcXJ8sbVAQBv%2BZemrh_p73sQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: One github repo, two pipelines, two distinct checks in github?

2017-09-15 Thread 'Ian Smith' via Jenkins Users
Hi Ann,

Thank you for that information. Sadly this isn't a viable option due to two 
reasons

   1. Having to embed the Github user token in the curl command, which 
   means adding that to the Jenkinsfile script
   2. The webhook still takes the value of the build state for the last 
   pipeline. So although I can define separate values and I see three check 
   marks in the PR in github, if the second pipeline marks the build as a 
   failure then the pr-merge status is also set to failure.

Kind regards, Ian

On Saturday, September 9, 2017 at 6:18:36 AM UTC+1, Ann B wrote:
>
> Hi Ian-
>
> I'm sorry that I cannot answer your question directly, as we do not use a 
> web hook.
>
> Have you thought of posting to the github statuses api - 
> https://developer.github.com/v3/repos/statuses/#create-a-status with a 
> separate link for each of your pipelines?   We kick off all of our pipeline 
> jobs in parallel (static, functional, unit, etc).  Each job adds a Statuses 
> link to the PR with an initial value of 'Pending' with a link to the 
> running job in jenkins.  As each parallel job finishes, it updates the PR 
> Status with 'Failed' or 'Passes'.
>
> Ann
>

-- 
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/a662c5ae-5c92-40ac-9169-9446477d9f60%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: One github repo, two pipelines, two distinct checks in github?

2017-09-08 Thread Ann B
Hi Ian-

I'm sorry that I cannot answer your question directly, as we do not use a 
web hook.

Have you thought of posting to the github statuses api - 
https://developer.github.com/v3/repos/statuses/#create-a-status with a 
separate link for each of your pipelines?   We kick off all of our pipeline 
jobs in parallel (static, functional, unit, etc).  Each job adds a Statuses 
link to the PR with an initial value of 'Pending' with a link to the 
running job in jenkins.  As each parallel job finishes, it updates the PR 
Status with 'Failed' or 'Passes'.

Ann

-- 
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/8d7627c3-f69e-4b95-ab8d-bb08e0ff3e0e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.