Re: Login Problems with issues.jenkins-ci.org - who to contact?

2020-12-02 Thread Richard Bywater
I suspect that the Jira sign-up link should actually probably be disabled
as if I'm not mistaken accounts need to be created via the accounts or
beta.accounts URL.

Hopefully someone who knows more about the new Jira setup can confirm or
deny that :)

Richard.

On Thu, 3 Dec 2020 at 06:24, Inga Quatuor  wrote:

> I am having a similar problem. I signed up at https://issues.jenkins.io/
> and I received a mail titled "[JIRA] Account signup" but I cannot login.
> Neither at https://accounts.jenkins.io/ nor
> https://beta.accounts.jenkins.io/ nor https://issues.jenkins.io/ . The
> password reset is also not working - I am not receiving any mails that way.
> As far as I can see there is no verification action required. The signup
> mail only contains 2 links ( https://issues.jenkins.io
> 
> and a link to reset your password ) and my account info.
>
> I tried signing up with different email adresses (the first three kinda
> similar with name.surname at different domains, the last one randomly
> generated at tempmail.org), tried passwords with differing complexies and
> tried different browser to no avail. No account let's me login.
>
> Any ideas?
>
> On Friday, November 27, 2020 at 12:28:42 PM UTC+1 yannick...@gmail.com
> wrote:
>
>> I am able to log in to https://accounts.jenkins.io/  and to
>> https://beta.accounts.jenkins.io/ but not https://issues.jenkins.io/
>> My password is already in ASCII range and there is not captcha on
>> https://issues.jenkins.io/
>>
>> On Fri, Nov 27, 2020 at 5:07 AM Mark Waite  wrote:
>>
>>> I've had to refresh the captcha on occasion to show an updated captcha
>>> that I can then enter.  You might try that?
>>>
>>> You might also try with a long password that uses only characters in the
>>> ASCII range.  I'm not sure how locale processing is handled in the password
>>> validation process.
>>>
>>> On Thu, Nov 26, 2020 at 8:30 PM Yannick Lacaute 
>>> wrote:
>>>
 I have reset my password with https://beta.accounts.jenkins.io/
 I am able to connect on https://beta.accounts.jenkins.io/
  but I
 still cannot log in issues.jenkins-ci.org.

 any idea ?

 Le jeudi 26 novembre 2020 à 01:29:55 UTC+1, Mark Waite a écrit :

> Try resetting your password through https://beta.accounts.jenkins.io/
> and then attempt to login to https://issues.jenkins.io/
>
> If that does not work, reply to this email and we'll try more
> diagnostics.
>
>
> On Wed, Nov 25, 2020 at 1:15 PM Ross Bender 
> wrote:
>
>> I am having the same issue. I have an account and can log into
>> https://accounts.jenkins.io/, but when I try logging into
>> https://issues.jenkins.io/ I receive the error "Sorry, your username
>> and password are incorrect - please try again."
>>
>> My username is l3ender. Can someone advise or assist? Thanks!
>>
>> On Friday, June 29, 2018 at 3:43:45 AM UTC-5 mark.ot...@gmail.com
>> wrote:
>>
>>> I have a co-worker that's been unable to get his
>>> issues.jenkins-ci.org Jira account working correctly.  Tried
>>> multiple browsers and still have the same issue.  He's able to login to
>>> https://accounts.jenkins.io/ just fine, but the same account
>>> doesn't work on issues.jenkins-ci.org
>>>
>>> Is there anyone he can contact for assistance?  I was unable to find
>>> any contacts on the websites themselves.
>>>
>>> Thanks!
>>> Mark
>>>
>> --
>> 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/38e55859-b849-415d-9120-f5c622d631b2n%40googlegroups.com
>> 
>> .
>>
> --
 You received this message because you are subscribed to the Google
 Groups "Jenkins Users" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to jenkinsci-use...@googlegroups.com.
 To view this discussion on the web visit
 https://groups.google.com/d/msgid/jenkinsci-users/b815ee90-74ea-4d6c-aad0-6959fc6b1789n%40googlegroups.com
 
 .

>>> --
>>> You received this message because you are subscribed to the Googl

Re: Jenkins' HTTP Request plugin does not wait until web page is loaded

2020-12-02 Thread 'Björn Pedersen' via Jenkins Users
Are you sure your GET request targets the right endpoint? If you get a 
loading mesage, this is a strong hint that there is ajax loading involved, 
which  the http requets plugin would not handle. 

Either find out the ajax endpoint you are  interessted in, or switch to 
e.g. using selenium in this case.

buntyhe...@gmail.com schrieb am Mittwoch, 2. Dezember 2020 um 18:23:58 
UTC+1:

> Hi all,
> I am using the 'HTTP Request' plugin available in Jenkins. I have to do a 
> GET request using this plugin. But the web page, I want to GET, takes a few 
> seconds to load the page.
> But, Jenkins completes the job and shows the 'loading' information in 
> response.
>
> Could someone please tell me how I can tell Jenkins to wait for a few 
> seconds and then read the page and return the actual content of the web 
> page?
>
> Thanks in advance.
>
> Regards,
> Nilesh
>

-- 
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/9d39b7d0-33e6-4160-8a85-2d2c9b41aba3n%40googlegroups.com.


Failed to load and run groovy script in a pipeline job

2020-12-02 Thread Owen Liu

Hi,

I want to load a groovy script and execute methods of that script in a 
simple scripted pipeline. but it failed to run the groovy script when 
loading the groovy script, the script is very simple, I tested it on my 
local computer, it ran successfully, I have the following configuration:
//Jenkinsfile
node("master"){
stage("test1"){

checkout([$class: 'GitSCM', branches: [[name: "refs/heads/master"]],
doGenerateSubmoduleConfigurations: false, extensions: [], submoduleCfg: [],
userRemoteConfigs: [[credentialsId: 'xxx', url:
"git@xxx:xxx.git"]]])

def script=load "${env.WORKSPACE}/scripts/debug1.groovy"
script.hello()
}
}

//scripts/debug1.groovy
def initVariableBindings() {
def tempArr=["WORKSPACE"]
tempArr.each {
if (System.getenv(it) != null) {
this.binding.setProperty(it, System.getenv(it))
} else if (System.getProperty(it) != null) {
this.binding.setProperty(it, System.getProperty(it))
} else {
println "Failed to init variable "+ it;
}
}
}
def hello(){
println "hello ${WORKSPACE}"
}
initVariableBindings()

it throws the following exception:

groovy.lang.MissingFieldException: No such field: binding for class: 
Script1 at groovy.lang.MetaClassImpl.getAttribute(MetaClassImpl.java:2846) 
at groovy.lang.MetaClassImpl.getAttribute(MetaClassImpl.java:3782) at 
org.codehaus.groovy.runtime.InvokerHelper.getAttribute(InvokerHelper.java:147) 
at 
org.codehaus.groovy.runtime.ScriptBytecodeAdapter.getField(ScriptBytecodeAdapter.java:306)
 
at org.kohsuke.groovy.sandbox.impl.Checker$9.call(Checker.java:437) at 
org.kohsuke.groovy.sandbox.GroovyInterceptor.onGetAttribute(GroovyInterceptor.java:96)
 
at 
org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SandboxInterceptor.onGetAttribute(SandboxInterceptor.java:438)
 
at org.kohsuke.groovy.sandbox.impl.Checker$9.call(Checker.java:434) at 
org.kohsuke.groovy.sandbox.impl.Checker.checkedGetAttribute(Checker.java:439) 
at 
com.cloudbees.groovy.cps.sandbox.SandboxInvoker.getAttribute(SandboxInvoker.java:37)
 
at 
com.cloudbees.groovy.cps.impl.AttributeAccessBlock.rawGet(AttributeAccessBlock.java:20)
 
at Script1.initVariableBindings(Script1.groovy:8) at 
com.cloudbees.groovy.cps.CpsDefaultGroovyMethods.each(CpsDefaultGroovyMethods:2030)
 
at 
com.cloudbees.groovy.cps.CpsDefaultGroovyMethods.each(CpsDefaultGroovyMethods:2015)
 
at 
com.cloudbees.groovy.cps.CpsDefaultGroovyMethods.each(CpsDefaultGroovyMethods:2056)
 
at Script1.initVariableBindings(Script1.groovy:4) at 
Script1.run(Script1.groovy:17) at ___cps.transform___(Native Method)



it complains that the List variable tempArr in the function 
initVariableBindings is not a binding property, but it is a local variable, 
it should work, is this normal behavior and why or a bug of groovy plugin? 

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/04d955dd-e2ce-4802-b195-dacb991d7fecn%40googlegroups.com.


Re: Login Problems with issues.jenkins-ci.org - who to contact?

2020-12-02 Thread Inga Quatuor
I am having a similar problem. I signed up at https://issues.jenkins.io/  
and I received a mail titled "[JIRA] Account signup" but I cannot login. 
Neither at https://accounts.jenkins.io/ nor 
https://beta.accounts.jenkins.io/ nor https://issues.jenkins.io/ . The 
password reset is also not working - I am not receiving any mails that way. 
As far as I can see there is no verification action required. The signup 
mail only contains 2 links ( https://issues.jenkins.io 

 
and a link to reset your password ) and my account info.

I tried signing up with different email adresses (the first three kinda 
similar with name.surname at different domains, the last one randomly 
generated at tempmail.org), tried passwords with differing complexies and 
tried different browser to no avail. No account let's me login.

Any ideas?

On Friday, November 27, 2020 at 12:28:42 PM UTC+1 yannick...@gmail.com 
wrote:

> I am able to log in to https://accounts.jenkins.io/  and to 
> https://beta.accounts.jenkins.io/ but not https://issues.jenkins.io/
> My password is already in ASCII range and there is not captcha on 
> https://issues.jenkins.io/
>
> On Fri, Nov 27, 2020 at 5:07 AM Mark Waite  wrote:
>
>> I've had to refresh the captcha on occasion to show an updated captcha 
>> that I can then enter.  You might try that?
>>
>> You might also try with a long password that uses only characters in the 
>> ASCII range.  I'm not sure how locale processing is handled in the password 
>> validation process.
>>
>> On Thu, Nov 26, 2020 at 8:30 PM Yannick Lacaute  
>> wrote:
>>
>>> I have reset my password with https://beta.accounts.jenkins.io/
>>> I am able to connect on https://beta.accounts.jenkins.io/ 
>>>  but I 
>>> still cannot log in issues.jenkins-ci.org.
>>>
>>> any idea ?
>>>
>>> Le jeudi 26 novembre 2020 à 01:29:55 UTC+1, Mark Waite a écrit :
>>>
 Try resetting your password through https://beta.accounts.jenkins.io/ 
 and then attempt to login to https://issues.jenkins.io/ 

 If that does not work, reply to this email and we'll try more 
 diagnostics.


 On Wed, Nov 25, 2020 at 1:15 PM Ross Bender  wrote:

> I am having the same issue. I have an account and can log into 
> https://accounts.jenkins.io/, but when I try logging into 
> https://issues.jenkins.io/ I receive the error "Sorry, your username 
> and password are incorrect - please try again."
>
> My username is l3ender. Can someone advise or assist? Thanks!
>
> On Friday, June 29, 2018 at 3:43:45 AM UTC-5 mark.ot...@gmail.com 
> wrote:
>
>> I have a co-worker that's been unable to get his 
>> issues.jenkins-ci.org Jira account working correctly.  Tried 
>> multiple browsers and still have the same issue.  He's able to login to 
>> https://accounts.jenkins.io/ just fine, but the same account doesn't 
>> work on issues.jenkins-ci.org
>>
>> Is there anyone he can contact for assistance?  I was unable to find 
>> any contacts on the websites themselves.
>>
>> Thanks!
>> Mark
>>
> -- 
> 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/38e55859-b849-415d-9120-f5c622d631b2n%40googlegroups.com
>  
> 
> .
>
 -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "Jenkins Users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to jenkinsci-use...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/b815ee90-74ea-4d6c-aad0-6959fc6b1789n%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Jenkins Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to jenkinsci-use...@googlegroups.com.
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtHcUOtHaux5wAnkPt6-M-m80QrSPhYdFwbaDDEaYo%2BT6A%40mail.gmail.com
>>  
>> 

Can't save job configuration - JSONObject["hudson-triggers-TimerTrigger"] is not a JSONObject

2020-12-02 Thread Inga Quatuor
Since Jenkins 2.264 I am encountering an error when either trying to modify 
the configuration of a job with a "Build periodically" trigger or when 
trying to add a "Build periodically" trigger to any job. The error - 
net.sf.json.JSONException: JSONObject["hudson-triggers-TimerTrigger"] is 
not a JSONObject - happens when I click on Save or Apply and the job 
configuration is not saved.

Downgrading to 2.263 resolves the error but that is not a long term 
solution (especially since I already upgraded some plugins that are now 
broken because they require a newer Jenkins version ... ).

After 2.264 I tried again with 2.269 today and I still run into this error.

In Jenkins' log I can see the JSON with the job configuration that fails to 
parse and it contains this:

"hudson-triggers-TimerTrigger": true,
"spec": "H 1 * * *",

based on the exception I suspect that this should be 

"hudson-triggers-TimerTrigger": {
"spec": "H 1 * * *"
 }

instead but I have no idea how I can fix this at my end.

If anyone knows a solution or a workaround I'd greatly appreciate it. I 
would report this at Jenkins Jira, but I can't login there :/

Thanks, Inga

-- 
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/6a785465-1815-4a24-945c-ed8ec57c840en%40googlegroups.com.


Jenkins' HTTP Request plugin does not wait until web page is loaded

2020-12-02 Thread Nilesh Tembhre
Hi all,
I am using the 'HTTP Request' plugin available in Jenkins. I have to do a 
GET request using this plugin. But the web page, I want to GET, takes a few 
seconds to load the page.
But, Jenkins completes the job and shows the 'loading' information in 
response.

Could someone please tell me how I can tell Jenkins to wait for a few 
seconds and then read the page and return the actual content of the web 
page?

Thanks in advance.

Regards,
Nilesh

-- 
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/c41d24f7-49b7-4e1a-bb6f-9a45b517bc72n%40googlegroups.com.


Re: different github checkout revisions

2020-12-02 Thread Mark Waite
On Wed, Dec 2, 2020 at 12:56 AM  wrote:

> Thanks for your reply.
> Temporarily, I have to roll back to the old, but working successfully
> solution with git:
>
> git(
> url: 'https://github.com/enterpr/myrepo.git',
> credentialsId: 'github-PAT',
> branch: "${params.branch_name}"
> )
>
> But I would like to solve my problem with checkout and incorrect revisions
> on each run.
> Here is the full code with checkout, which randomly gives different
> revisions:
>
> checkout ([
>$class: 'GitSCM',
>branches: [[name: '"*/"${params.branch_name}']],
>doGenerateSubmoduleConfigurations: 'false',
>extensions: [[$class: 'CheckoutOption', timeout: 180],[$class:
> 'CloneOption', depth: 1, noTags: true, reference: '', shallow: true,
> timeout: 60]],
>submoduleCfg: [],
>userRemoteConfigs: [[url: 'https://github.com/enterpr/myrepo.git',
> credentialsId: 'github-PAT']]])
>
> {Params. branch_name} always has the same value - branch 'dev'
>
>
Try this instead:

  checkout ([
   $class: 'GitSCM',
   branches: [[name: params.branch_name]],
   extensions: [[$class: 'CheckoutOption', timeout: 180],[$class:
'CloneOption', depth: 1, noTags: true, reference: '', shallow: true,
timeout: 60]],
   userRemoteConfigs: [[url: 'https://github.com/enterpr/myrepo.git',
credentialsId: 'github-PAT']]])

Since you're cloning from a single repository, you don't need the leading
'*/' to precede the branch name.

Since you want to use the value of params.branch_name you don't need to
embed that in single quotes.

Since you're using the default values for doGenerateSubmoduleConfigurations
and  submoduleCfg , you don't need to specify them.

If your checkout only requires one branch, then you can reduce the work on
the remote server and the disc space on the agent by using the "honor
refspec on initial clone" along with a specifically defined refspec that
uses only the specific branch.  Examples of intentionally narrowed refspecs
are available in several places, including this repository

.



> >However, you didn't tell us if this is a Pipeline job with the script
> inside the job, a Pipeline job that is getting the script from SCM...
> My pipeline is loaded from SCM (github) as a script code (Pipeline)
> (enabling or disabling Lightweight checkout in the pipeline settings does
> not affect issue with different revisions).
>
> >  When you say "restart the same pipeline", do you mean that you press
> the "Replay" button for the pipeline?
> Any launch "Build with parameters" or "Restart from stage", because in
> each stage I have code with "checkout" call.
>
> >Is there something special about the local file system that causes you to
> set the checkout timeout (a local file system operation) to allow more time
> that the clone timeout (which is a network operation)?
> If You mean the set values of [timeout: 180 & timeout: 60] in my code,
> then these parameters were added intentionally, because earlier when using
> git, where this default value is [timeout: 10], there were regular problems
> when loading my large repository.
>
>
Yes, those are exactly what I mean.  If you're using a git repository that
is large enough to exceed the default 10 minute timeout when cloning the
repository, you probably should review the "Git in the Large
" video segment that will point you to
the things you can do on Jenkins agents to significantly reduce the time
and the disc space cost of large repositories.  The key items (in priority
order) are:


   1. Reference repository on the agent in a known location (almost always
   effective at reducing data transfer and data storage on agents)
   2. Narrow refspec for the job and honor refspec on initial clone
   (effective for repositories with many branches that have largely
   independent branches, less effective for large repositories with
   interdependent branches0
   3. Shallow clone (not nearly as effective as I'd hoped)


Your current settings allow up to 60 minutes to pull the repository data
from the remote git server, then allow up to 180 minutes to perform the
local checkout on the agent file system.  That is a surprising combination
of values.  Access to the agent file system is usually significantly faster
than access to the remote git repository.  If that is not the case in your
installation, then you may need to investigate why file system access to
the agent file system is slower than network access to a git repository.


> I am sure that this is an error in checkout, because without any changes
> in the SCM or code, restarting the same pipeline can take different
> revisions.
> How do I always ensure the latest revision?
>
>
>
>
> On Tue, Dec 1, 2020 at 5:32 AM  wrote:
>
> There is such a jenkins-code:
>
> checkout ([ ...
> extensions: [[$class: 'CheckoutOption', timeout: 180

Re: Authorization on Multibranch Pipeline

2020-12-02 Thread Victor Martinez
I'm not sure if for the same Multibranch Pipeline there are certain 
authorisations for branches, but creating two Multibranch Pipelines for 
those branches and add the authorization at the project level might fulfill 
your needs:


On Wednesday, 2 December 2020 at 03:54:08 UTC Rishi Gautam wrote:

> some way to restrict User1 to  trigger the build button from console on 
> master branch?
>
> On Wed, Dec 2, 2020 at 2:03 AM Jibsan Joel Rosa Toirac  
> wrote:
>
>> Well I solved the problem, I used "sudo" before the commands and it 
>> started to work, anyhow I ran the command 
>> "root/.sdkman/candidates/grails/3.3.2/bin/grails war" and all started to 
>> work. Thanks for your help
>>
>> El mar, 1 dic 2020 a las 10:30, Rishi Gautam () 
>> escribió:
>>
>>> Is there any way to enable authorization to build only specific 
>>> branch(job) on jenkins multbranch pipeline?
>>>
>>> Use Case:
>>> User1: can only build test branch.
>>> User2: can build both test and master branch.
>>>
>>> It would be very helpful to get the solution. 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-use...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/86a58043-d55c-40ac-ae59-3f9e185b53bbn%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Jenkins Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to jenkinsci-use...@googlegroups.com.
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/CAAFuM4EEgdmSJZKbksDY05WB1qKY1-Oyp3_0puU9zHhCocwG-Q%40mail.gmail.com
>>  
>> 
>> .
>>
>

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