Re: Version Disclosure (JQuery/YUI/Prototypejs)

2024-03-21 Thread 'Björn Pedersen' via Jenkins Users


s.p...@gmail.com schrieb am Donnerstag, 14. März 2024 um 15:10:24 UTC+1:

Please help.

On Wednesday, March 13, 2024 at 3:27:25 PM UTC-4 s.p...@gmail.com wrote:

Our web scans are showing Version disclosure for Jquery/YUI/Prototyejs . 
Jenkins is running on windows server . Version is 2.426.3 The remedy our 
security team suggesting is : Configure your web server to prevent 
information leakage.I'm not sure how to configure the web server.Any 
steps/information is really appreaciated. TIA



To me this requirement does not really make sense, as jenkins is opensource 
and the versions of libraries used  are publicly known.  This one of the 
case of pseudo-security by obscurity.
 

-- 
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/29a0050b-ae4b-4f76-84ff-e54015c4b861n%40googlegroups.com.


Re: java.io.IOException: error=2, No such file or directory

2024-03-07 Thread 'Björn Pedersen' via Jenkins Users


guruc...@googlemail.com schrieb am Donnerstag, 7. März 2024 um 10:26:40 
UTC+1:


Hello, 

We're facing the problem that jobs are failing with such errors: 
... 
[SLNPBasicMvn] $ mvn clean install findbugs:findbugs pmd:pmd 
checkstyle:checkstyle 
Caused: java.io.IOException: Cannot run program "mvn" (in directory 
"/appdata/sisis/jenkins/workspace/SLNPBasicMvn"): error=2, No such file or 
directory 


Looks like a problem with your PATH settings... 

A jenkins restart fixes the issue without any other changes. 


 

There is nothing visible in /var/log/jenkins/jenkins.log. This is with 
version 2.401.3 on RH 8.9 (Ootpa). 

Any ideas? 

matthias 

-- 
Matthias Apitz, ✉ gu...@unixarea.de, http://www.unixarea.de/ 
+49-176-38902045 
Public GnuPG key: http://www.unixarea.de/key.pub 

I am not at war with Russia. Я не воюю с Россией. 
Ich bin nicht im Krieg mit Russland. 

-- 
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/4210c962-0084-48a8-8c78-7968d02149edn%40googlegroups.com.


Re: doesn’t have label

2023-10-12 Thread 'Björn Pedersen' via Jenkins Users


Mark Waite schrieb am Mittwoch, 11. Oktober 2023 um 20:07:29 UTC+2:

I've sometimes seen something like that when working with the static agents 
that I have connected to my controller.  I workaround the problem by adding 
a "junk" label to any one of the agents.  After saving the junk label, I 
configure the agent again to remove the "junk" label and that seems to 
cause jobs to again recognize agent labels.

On Wednesday, October 11, 2023 at 10:39:22 AM UTC-6 alok.d...@gmail.com 
wrote:

We recently got into an issue where Jenkins master is failed to 
schedule/distribute builds even though a lot of build agents are sitting 
idle. We noticed this problem with both ec2 fleet and ec2 (on-demands) 
plugins. 

Most of the jobs are stuck in the queue with the following message but 
nodes with the required labels are up in the UI. 

Anyone has experienced similar behavior? Any suggestions to fix this? 
Thanks. 
Still waiting to schedule task Waiting for pending items to get a node 
assigned ‘aws-dev-deploy-6’ doesn’t have label ‘docker’ ‘aws-dev-deploy-8’ 
doesn’t have label ‘docker’ ‘aws-prod-deploy-5’ doesn’t have label ‘docker’ 
‘aws-prod-deploy-6’ doesn’t have label ‘docker’ ‘aws-prod-deploy-7’ doesn’t 
have label ‘docker’ ‘i-09a2be6382fc26e24’ doesn’t have label ‘docker’ 
‘i-0a0347c44f3325130’ doesn’t have label ‘docker’ ‘i-0a2dd9e65b696c5a2’ 
doesn’t have label ‘docker’ ‘j1-android i-03006f1500a1a0c49’ doesn’t have 
label ‘docker’ ‘j1-docker i-009e0ccbd3a9616d3’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-00327f98f2b84ccd0’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-007332676d8b4a5f6’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-07a579dbf80a63d27’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-07c99149550e0be53’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-08c0f86b1dfeb58c0’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-0a55498b644f1a18a’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-0b4f913462a670fa3’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-0ca4a73a0bb975df6’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-0dd7e76088df5c56d’ doesn’t have label ‘docker’ 
‘j1-jenkinsfilerunner i-0ee7610539156599c’ doesn’t have label ‘docker’ 
‘j1-linux i-0058f862d193df3ea’ doesn’t have label ‘docker’ ‘j1-linux 
i-00656f1ae9f80073a’ doesn’t have label ‘docker’ ‘j1-linux 
i-012491b4a3876bef0’ doesn’t have label ‘docker’ ‘j1-linux 
i-0177b40a2676cc70a’ doesn’t have label ‘docker’ ‘j1-linux 
i-0285a836ca10ea06a’ doesn’t have label ‘docker’ ‘j1-linux 
i-03bf1b363f722977e’ doesn’t have label ‘docker’ ‘j1-linux 
i-03dcba2eed6a02624’ doesn’t have label ‘docker’ ‘j1-linux 
i-03eafa4b54936f82e’ doesn’t have label ‘docker’ ‘j1-linux 
i-04077c54f1352eaec’ doesn’t have label ‘docker’ ‘j1-linux 
i-059e9e4d333245344’ doesn’t have label ‘docker’ ‘j1-linux 
i-08559e6d9be2dab5c’ doesn’t have label ‘docker’ ‘j1-linux 
i-08dfca6d3b1176a11’ doesn’t have label ‘docker’ ‘j1-linux 
i-090bee3bdf40db6ea’ doesn’t have label ‘docker’ ‘j1-linux 
i-09a71e57be1518373’ doesn’t have label ‘docker’ ‘j1-linux 
i-0a06b985fea4aeef7’ doesn’t have label ‘docker’ ‘j1-linux 
i-0b868611590a750a6’ doesn’t have label ‘docker’ ‘j1-linux 
i-0e5597e6c71593762’ doesn’t have label ‘docker’ ‘j1-linux 
i-0f8bd2f10aaf9aa11’ doesn’t have label ‘docker’ ‘j1-linux 
i-0fd49a3eeb2c6d1a1’ doesn’t have label ‘docker’ 




Affected by https://issues.jenkins.io/browse/JENKINS-71937?  Should be 
fixed in latest weekly (2.427).
 

 Help us localize this page 


-- 
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/af8c00bb-aced-4585-984b-b3af28ca9741n%40googlegroups.com.


Re: Regarding two jenkins jobs

2023-08-10 Thread 'Björn Pedersen' via Jenkins Users


ashok...@gmail.com schrieb am Donnerstag, 10. August 2023 um 03:54:11 UTC+2:

Hi All, 

How to configure jenkinsfile if one job is in one jenkins instance and 
another job is in another jenkins instance?


I you really mean 2 jenkins instances (not different agents):

* don't use a single Jenkinsfile, instead configure the jobs (at least on 
one instance) to  use another name (e.g. jenkinsfile.host). 
* or  switch execution based on the HUDSON_URL variable (this gives the 
main jenkins URL), although this most likely will make the jenkinsfile 
quite unreadable.


-- 
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/7c6eee8d-3526-41cf-a758-f0f32523dd8an%40googlegroups.com.


Re: Jenkins / Unity / Guthub integration

2023-08-03 Thread 'Björn Pedersen' via Jenkins Users


andrew@googlemail.com schrieb am Freitag, 28. Juli 2023 um 14:28:33 
UTC+2:

I am  novice to using Unity and Jenkins.

make: [makefile:57: default] Error 1 (ignored) + echo 0

How do I get Unity/Jenkins to detect that the individual test has failed.  
The icing on the cake would be to somehow mark the git commit as a failure 
also.


 This the problem:  your makefile or test run script (as you did not post 
the complete setup it's hard to guess) should return with a non-zero status 
to fail the  step.
Alternativly you could use either  the JUnit Plugin (if you can produce a 
junit-comaptible output) or Warnings Next Generation Plugin ( which is 
highly customisable to parse any output) to fail the build.

 


Thank 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/55344762-47ce-4406-b809-e69f14972e60n%40googlegroups.com.


Re: Could not update folder level actions from source FATAL: "Failed to recompute children" when indexing multibranch pipeline

2023-06-18 Thread 'Björn Pedersen' via Jenkins Users


ashis...@gmail.com schrieb am Donnerstag, 15. Juni 2023 um 20:19:54 UTC+2:

Hi All,

I'm getting this following error which is happening for a particular gerrit 
repo. The configuration is working for all other repos in my project but 
not in this particular one.





















*ERROR: [Thu Jun 15 17:55:03 UTC 2023] Could not update folder level 
actions from source c0628d20-0427-4a13-a81d-b22ef9bfe114[Thu Jun 15 
17:55:03 UTC 2023] Finished branch indexing. Indexing took 0.56 secFATAL: 
Failed to recompute children of 
test-seatregionhudson.plugins.git.GitException: Command "git fetch --tags 
--force --progress -- origin +refs/heads/*:refs/remotes/origin/* 
refs/changes/62/113962/4:refs/remotes/origin/62/113962/4 
refs/changes/85/115185/2:refs/remotes/origin/85/115185/2 
refs/changes/24/106224/4:refs/remotes/origin/24/106224/4" returned status 
code 128:stdout: stderr: remote: Counting objects: 1   fatal: 
protocol error: bad pack header at 
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2734)
 
at 
org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:2111)
 
at 
org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:623) 
at 
jenkins.plugins.gerrit.AbstractGerritSCMSource.doRetrieve(AbstractGerritSCMSource.java:670)
 
at 
jenkins.plugins.gerrit.AbstractGerritSCMSource.retrieveActions(AbstractGerritSCMSource.java:232)
 
at jenkins.scm.api.SCMSource.fetchActions(SCMSource.java:848) at 
jenkins.branch.MultiBranchProject.computeChildren(MultiBranchProject.java:597) 
at 
com.cloudbees.hudson.plugins.folder.computed.ComputedFolder.updateChildren(ComputedFolder.java:278)
 
at 
com.cloudbees.hudson.plugins.folder.computed.FolderComputation.run(FolderComputation.java:166)
 
at 
jenkins.branch.MultiBranchProject$BranchIndexing.run(MultiBranchProject.java:1031)
 
at hudson.model.ResourceController.execute(ResourceController.java:101) at 
hudson.model.Executor.run(Executor.java:442)Finished: FAILURE*


Sounds more like a problem on the gerrit side. Maybe 
check 
https://confluence.atlassian.com/fishkb/git-indexing-fails-due-to-bad-pack-header-371360062.html
 
for one reason.
 

The multibranch pipeline catalog template is
multibranch:
  branchSource:
gerrit:
  remote: ${ProjectRepositoryUrl}
  credentialsId: ${GitHTTPSCredentials}
  traits:
- $class: ChangeDiscoveryTrait
  queryString: ''
- $class: RefSpecsSCMSourceTrait
  templates:
  - value: '+refs/heads/*:refs/remotes/@{remote}/*'
- $class: SubmoduleOptionTrait
  extension:
disableSubmodules: false
recursiveSubmodules: true
parentCredentials: true  

and pipeline config is 
pipeline {
/**## Agents Config ##**/
agent {
kubernetes {
inheritFrom "${PodName}"
}
}
options {
// This will checkout the changed repository that has triggered 
this pipeline to a sperate folder named "tmp_repository", to be used later 
in the build
checkoutToSubdirectory('tmp_repository')
buildDiscarder(logRotator(numToKeepStr: 'unlimited'))
}

/**## Stages ##**/
stages {
/**## Gerrit Review Log 
##**/
stage('Init') {
steps {
script {
gerritReview message: "Build started: ${BUILD_URL}"
}
}
}
/**## Cloning Manifest Repository 
##**/
stage('Cloning Manifest Repo') {
steps { // Executes on JNLP, no specific container required
script {
echo "Cloning the Manifest repository: ${
ManifestRepoName}"
// This will checkout the manifest repository into a 
folder under the same name as the repository
dir("${ManifestRepoName}") {
checkout([
$class: 'GitSCM',
branches:
[[name: "*/${ManifestBranch}"]],
doGenerateSubmoduleConfigurations: false,
extensions: [[
$class: 'LocalBranch',
localBranch: '**'
  ],[
$class: 'CleanBeforeCheckout',
deleteUntrackedNestedRepositories: false
  ]],
submoduleCfg: [],
userRemoteConfigs: [[credentialsId: 
GitHTTPSCredentials, /*Netid credentials must be used instead of HTTPS 
tokens.*/
 url: ManifestRepoUrl]]
])
}
}
}
}
}


The multibranch indexing itself is 

Re: Jira Issue

2023-05-19 Thread 'Björn Pedersen' via Jenkins Users


saravan...@gmail.com schrieb am Donnerstag, 18. Mai 2023 um 15:03:55 UTC+2:

Hi

Iam not getting any comments in JIra, showing below error. can you please 
tell what this error means.

expected to call springBootPipeline.addJiraComments but wound up catching 
jiraComment; see: 
https://jenkins.io/redirect/pipeline-cps-method-mismatches/


One of the mistakes mentioned in the linked page is made in your pipeline 
(or included libs). Whcih one is hard to tell without seeing the pipeline 
definition

 

Thanks
P.Saravanan

-- 
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/1d7a9b26-69e1-4486-b91a-79b129810df4n%40googlegroups.com.


Re: Weird behaviour after plugin updates

2023-04-21 Thread 'Björn Pedersen' via Jenkins Users
>From the backtrace and the description is seems a problem with the 
authorize-project plugin and restarts ( I guess the limitations for Run as 
user who started the job apply for restarts/resumed jobs  as well, as these 
are essentially scheduled jobs after the restart). 
So you would need to make sure you only restart the server with no jobs 
active/queued.

Björn

christop...@googlemail.com schrieb am Freitag, 21. April 2023 um 08:39:36 
UTC+2:

> It didnÄt appear for a while so I hoped the problem was solved but after 
> the last update it happened again.
> Even the scheduled builds don't run when this happens...
>
> christop...@googlemail.com schrieb am Dienstag, 31. Januar 2023 um 
> 10:56:25 UTC+1:
>
>> This morning it happened again just after the update of two plugins.
>>
>> I found a lot of this in the log:
>>
>> Caught exception evaluating: h.getJobPropertyDescriptors(it) in 
>> /view/XXX/job/YYY/configure. Reason: java.lang.IllegalStateException: The 
>> class jenkins.security.QueueItemAuthenticatorConfiguration was not found, 
>> potentially not yet loaded java.lang.IllegalStateException: The class 
>> jenkins.security.QueueItemAuthenticatorConfiguration was not found, 
>> potentially not yet loadedat 
>> hudson.ExtensionList.getInstance(ExtensionList.java:166)at 
>> jenkins.security.QueueItemAuthenticatorConfiguration.get(QueueItemAuthenticatorConfiguration.java:60)
>>  
>>at 
>> org.jenkinsci.plugins.authorizeproject.ProjectQueueItemAuthenticator.getConfigured(ProjectQueueItemAuthenticator.java:178)
>>  
>>at 
>> org.jenkinsci.plugins.authorizeproject.ProjectQueueItemAuthenticator.isConfigured(ProjectQueueItemAuthenticator.java:190)
>>  
>>at 
>> org.jenkinsci.plugins.authorizeproject.AuthorizeProjectProperty$DescriptorImpl.isApplicable(AuthorizeProjectProperty.java:178)
>>  
>>at 
>> hudson.model.JobPropertyDescriptor.getPropertyDescriptors(JobPropertyDescriptor.java:101)
>>  
>>at hudson.Functions.getJobPropertyDescriptors(Functions.java:932)at 
>> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native 
>> Method)at 
>> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown 
>> Source)at 
>> java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown 
>> Source)at java.base/java.lang.reflect.Method.invoke(Unknown Source)   
>>  at 
>> org.apache.commons.jexl.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:258)
>>  
>>at org.apache.commons.jexl.parser.ASTMethod.execute(ASTMethod.java:104)
>> ...
>>
>>
>> christop...@googlemail.com schrieb am Donnerstag, 19. Januar 2023 um 
>> 14:38:05 UTC+1:
>>
>>> Ah, and when I'm talking about random effects after an upgrade combined 
>>> with a restart: I observed lost labels of lockable resources since a 
>>> similar period of time. This happened also right now after the last upgrade.
>>>
>>> christop...@googlemail.com schrieb am Donnerstag, 19. Januar 2023 um 
>>> 11:06:41 UTC+1:
>>>
 Hi,

 since a couple of months I'm observing a weird behavior of my jenkins 
 installation after plugin upgrades.

 I am running LTS (currently 2.375.2) on a windows server and updating 
 very close to each kind of update releases (jenkins itself as well as 
 plugins).
 After updates using plugin manager I manually restart the windows 
 service (in the past I had cases where builds after a restart suddenly 
 were 
 very slow. A service restart avoids that.

 Now the issue: right after a restart after an update I can't start jobs 
 manually and I did not find out yet what makes them start again. Might be 
 a 
 couple of restarts in a row. Might be a delay of a fixed time. I don't 
 know 
 and that makes me nervous every time.

 Is there an intended delay after upgrades (how long?) or is this some 
 sort of bug?

 BR,
 Christoph

>>>

-- 
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/bbbd8804-cc53-4c17-aace-801de4f585fen%40googlegroups.com.


Re: Regarding unable to view the jobs in jenkins

2023-03-27 Thread 'Björn Pedersen' via Jenkins Users


ashok...@gmail.com schrieb am Montag, 27. März 2023 um 08:56:17 UTC+2:

ErrorNote: My mgmt suggested me to use jenkins 2.176.1 version and do not 
upgrade. 

Can you please suggest? 


You have  the following options:
 - install jenkins in a supported version ( LTS or the  latest weekly 
releases) on a  supported java version, update regularly, enjoy the latest 
plugin updates and get support here
 - use an horribly outdated version, accept that many plugins are not 
available, have many security flaws and manage everything on your own.
 

 


On Mon, 27 Mar 2023 at 2:36 PM, Ashok Reddy  wrote:

Okay Noted. But we are using  java8 and use jenkins 1.176.1 version.
 
I am unable to install the plugins in jenkins 1.176.1 version. 

Can you please help me?


Note: I should not go for another version.

On Mon, 27 Mar 2023 at 1:30 PM, 'Dirk Heinrichs' via Jenkins Users <
jenkins...@googlegroups.com> wrote:

Am Samstag, dem 25.03.2023 um 10:26 +0800 schrieb Ashok Reddy:

For most of the applications , we are using java8. 
Hence , the new jenkins version which is not supported for java8.


The Java version Jenkins runs on is independent of the Java version used by 
your apps.

HTH...

-- 
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/553da7c3-a1a5-4267-9fe9-d70dd7840009n%40googlegroups.com.


Re: Issue with the Jenkins Plugin emailext Plugin.

2023-02-17 Thread 'Björn Pedersen' via Jenkins Users


slide schrieb am Mittwoch, 15. Februar 2023 um 19:46:07 UTC+1:
Can you check the Jenkins logs and see if there is a full exception trace 
in the log?

On Wed, Feb 15, 2023 at 11:01 AM Chetan  wrote:
Hi

Yes the failure.html will created in workspace before calling the emailext. 
Also it will not happen everytime. 

I'm trying to figure out does it somehow depend on the nodes we use. Also i 
believe the content of failure.html might be causing the issue as it will 
have many logs lines entries.

On Wed, 15 Feb, 2023, 7:23 am Alex Earl,  wrote:
Does failure.html exist in the root of the workspace?

On Fri, Feb 3, 2023, 03:35 Chetan  wrote:
Hi Jenkins Experts

I get the below error message sometime only when i use the html file as 
email.

Jenkins Code:

 emailext (
mimeType: 'text/html',
subject: 'Compilation Varification Failed for Gerrit',
attachLog: true,
attachmentsPattern: 'Errors/*.log,BTLD/Errors/*.log',
body: '${FILE, path="failure.html"}',
from: 'tbu...@harman.com',
to : 
'$GERRIT_CHANGE_OWNER_EMAIL,$GERRIT_PATCHSET_UPLOADER_EMAIL'
)


Instead of inlininig a possibly huge file in the email-body, did you 
consider adding it as an attachment instead?



 
*Error: *
*[Error replacing 'FILE' - Error processing tokens]*








Thanks & Best Regars

*Chetan B*

-- 
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%2B6q8-5vQ7Z430Mi6pqCUL8pP7n%3DR04MFUTCGifBMPyTQcLtEw%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-use...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAPiUgVfoxQ%3D47qUiyVMv0gdyHCRPaZdh_nOkfpNCZ6RN%3Dqh-5Q%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-use...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CA%2B6q8-7AP16183Ghyx0GFvFot5%3Ddqr4NvD1JU37Fuk00RMgp9Q%40mail.gmail.com
 

.


-- 
Website: http://earl-of-code.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/1c4136a9-ee83-4b4e-a2b1-b10cd09ee104n%40googlegroups.com.


Re: Poll git removes build artifacts/clean repository on node workspace

2023-01-17 Thread 'Björn Pedersen' via Jenkins Users


zakyn schrieb am Dienstag, 17. Januar 2023 um 16:57:45 UTC+1:
Hello,
thank you.

The job is defined as a jenkinsfile with the polling and git checkout and 
other build steps.
The snippet of jenkinsfile is below.

After deeper investigation just at the time when polling is executed (every 
hour) the build files from the workspace on the node
are removed and the repository stays there. 

We are using the artifacts but sometimes you need some intermediate files 
that's why we do not delete workspace after job but before.

We are migrating from jenkins2.222.3 (everything works)  -> 2.375.2   

Thank you for your help.

Vladimir

---
Jenkinsfile part:

triggers{
pollSCM('@hourly') 
}

   stage('Clean workspace'){
   
steps{
cleanWs deleteDirs: true, patterns: [[pattern: 
'**/.git/**', type: 'EXCLUDE']]
}
}


I guess the polling triggers the job and then the deletion is expected. 
--
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/5bb24922-02c7-462c-9725-3411e47f966fn%40googlegroups.com
 

.

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


Re: Poll git removes build artifacts/clean repository on node workspace

2023-01-17 Thread 'Björn Pedersen' via Jenkins Users


zakyn schrieb am Dienstag, 17. Januar 2023 um 10:13:21 UTC+1:
Hello,
we have a problem that polling git clean the repository in workspace on the 
node.

Steps:
1. clone git repository  and  build
2. build artifacts are in workspace on the node
3. press poll smc button -> build artifacts are removed from workspace on 
the node and the clean repository is still available.

Could you please help me how to get a rid of this behavior?


First:
You should always consider workspaces ephemeral (they can get 
cleaned/removed by jenkins at anytime(if not in use).
If you want to keep artifacts then use an archive artifacts step or push 
them to some other repo (by scp, upload, whatever...) as appropriate.

If you want more help, please specify exactly how your job is configured.
 
Thank you.

Vladimir 

-- 
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/5bb24922-02c7-462c-9725-3411e47f966fn%40googlegroups.com.


Re: Another way to uninstall a plugin?

2023-01-02 Thread 'Björn Pedersen' via Jenkins Users


zil...@gmail.com schrieb am Sonntag, 1. Januar 2023 um 19:16:34 UTC+1:

> Jenkins v2.346.3 running as a docker container
>
> I go to the Plugins Manager page, click the red-circled "x" and see 
> "Uninstallation pending". I then restart Jenkins via "
> myJenkins.domain.com/restart", but then see the plugin there again. What 
> gives? Is there a different way to uninstall a plugin? I have access to the 
> $JENKINS_HOME/plugins directory
>
>
Most probably this plugin is a dependency of another plugin (possibly due 
to core version dependency if it was a core plugin once), so it gets 
reinstalled automatically 
 

> TIA
> Chris
>

-- 
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/6cf13cb8-b931-4ce8-87cb-559ac1ce514fn%40googlegroups.com.


Re: git checkouts always set to controller user, causing problems with latest git

2022-11-02 Thread 'Björn Pedersen' via Jenkins Users


Mark Waite schrieb am Freitag, 28. Oktober 2022 um 15:17:21 UTC+2:

> I suspect that you'll find that something is misconfigured in your agent 
> definition rather than an issue in the checkout step.
>
> I think you'll be able to see that if you:
>
>1. Create a file in the workspace from inside the Pipeline
>2. Check the permissions of the created file
>
> I suspect you'll see that the permissions are the same as the permissions 
> generated by the checkout scm task.
>
>
I found the core cause:  
 https://github.com/jenkinsci/git-plugin/pull/1237/ disables the hooks by 
default. So I just need to re-nable hooks where they 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/fdaf81a1-0788-47cf-aaef-eb8248acd42cn%40googlegroups.com.


git checkouts always set to controller user, causing problems with latest git

2022-10-28 Thread 'Björn Pedersen' via Jenkins Users
In our setup we  run the agents  a separate user via ssh ( contoller: 
jenkins, agent: jenkinsworker).

In a pipeline we  checkout some code:
```
node(agent) {
   checkout git+ssh://.
  }
```
This  results in the workdir and all git files belonging to the user 
jenkins,  not jenkinsworker.

Trying to do a commit (with the need to run a commit-msg hook) fails to run 
the hook unless I explicitly allow the directory as  safe and correct the 
hook path (it is set to /dev/null if the directory belongs to an other user 
).

I would have  expected the workdir to be owned  by the agent user.

-- 
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/6e3b-eeed-44a3-8ee3-82330923782dn%40googlegroups.com.


Re: LLVM scan-build jenkins plugin throws NullpointerExceptions

2022-07-27 Thread 'Björn Pedersen' via Jenkins Users
I would suggest to check if clang is supported by the warnings-ng 
 plugin  (I would expect it does 
support it). 

Björn

Peter schrieb am Mittwoch, 27. Juli 2022 um 02:08:22 UTC+2:

> Hi,
> upgrading to jenkins weekly every now and then, i do get this in my logs 
> since 14th of July 2022. Anyone else?
>
> Publishing Clang scan-build results 
> ERROR: Build step failed with exception
> java.lang.NullPointerException at 
> jenkins.plugins.clangscanbuild.publisher.ClangScanBuildPublisher.perform(ClangScanBuildPublisher.java:169)
>  
> at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
> at 
> hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:816)
>  
> athudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:765)
> at hudson.model.Build$BuildExecution.post2(Build.java:179)
> ...
> Build step 'Publish Clang Scan-Build Results' marked build as failure.
>
> https://plugins.jenkins.io/clang-scanbuild/ is at version 1.8 (released 6 
> years ago)
> LLVM scan-build used here is version 12.0.1. Any hints how to solve this 
> issue?
>
>  Cheers, Peter
>

-- 
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/326bc664-e8d0-4d00-ad20-5b47077562efn%40googlegroups.com.


Re: jenkins parameters issues

2022-06-28 Thread 'Björn Pedersen' via Jenkins Users


zzgua...@gmail.com schrieb am Freitag, 24. Juni 2022 um 16:13:22 UTC+2:

> Hi team,
>   I have such a requirement on the Jenkins pipeline: when creating 
> parameters, there is a booleanParam parameter A, when A is true, I want the 
> extendedChoice boxes will pop up automatically, and the multi-select 
> parameters of this box will be passed to later use, when A is false I need 
> this optional box is not displayed, and this false value is also used in 
> the back, how can I implement it, or what can I refer to, thank you
>

Take a look a Active Choice plugin, this could solve the problem. And be 
aware that extended-choice is  
vulnerable: https://www.jenkins.io/security/advisory/2022-03-15/#SECURITY-2232

-- 
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/c1b11689-2d74-4c08-95cd-f5cc6b63f108n%40googlegroups.com.


Re: Gerrit publish just run one build

2022-03-07 Thread 'Björn Pedersen' via Jenkins Users


jimsearle schrieb am Freitag, 4. März 2022 um 21:41:56 UTC+1:

> Hi,
>
> We have been longtime Jenkins user and recently started the transition to 
> Gerrit.
>
> The Jenkins Gerrit trigger kicks off the job for each commit that is in 
> the publish, but we would prefer just to run the job on the last changeset 
> which includes all the commits.  This seems like it would be a common thing 
> and available in the configuration somewhere but I can't find anything.
>
>
Your terminology is a bit unclear, so I'll try to translate it to typical 
gerrit terms:
In gerrit you have changes (also called changesets) that are a single 
commit. So running a job  for each commit is normal (in the gerrit world).
  => this is trigger 'patchset-created' 
Note that updates to such a change are done by amending the local commit, 
not  by adding another commit in series and then pushing again to gerrit.
This gives a new patchset on the change.  A change in gerrit is 
fundamtentally different from a  pull request in the github/gitlab world.


 Once all votes are in placesuch a commit  can get "submitted" => merged to 
it's branch. 
  ==> trigger: change-merged

So I would say gerrit trigger behaves as expected...

Björn
 

> I can describe in more detail if this description is not clear.
>
> Thanks,
> Jim
>
>

-- 
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/165caaac-88ca-4b02-a5a1-ff17d5688d58n%40googlegroups.com.


Re: Trigger upstream job

2021-12-19 Thread 'Björn Pedersen' via Jenkins Users
You should really think through what you want and always keep the jobs 
hierachically ordered. To accomplish what  you want you need an explict 
trigger Job1 step (maybe a plugin is needed for freestyle builds). But 
beware that if you also have a trigger in job2 that triggers after job1 
success, then you may easily create an endless loop




adharsh...@gmail.com schrieb am Montag, 20. Dezember 2021 um 06:12:44 UTC+1:

> Hi,
>
> Requirment is to trigger the upstream job( freestyle jobs). Can anyone 
> please help in this.
>
>
> On Fri, 17 Dec 2021, 8:10 pm ,  wrote:
>
>> Hi Adharsha,
>>
>> We don’t use freestyle, so I may not be the best person to help you.
>>
>> I’m struggling although to understand the logic you want to implement.
>>
>> You said that in the “second job” configuration you configured “build 
>> trigger” and selected “first job”.
>>
>> But then you said you click “Build Now” on the “second job”.
>>
>> That is not how the “build trigger” works.
>>
>> On the basis of your configuration, it’s when you click “Build Now” on 
>> the “first job” that the “second job” will be triggered if the “first job” 
>> succeed.
>>
>>  
>>
>> Probably you got confused by the difference in English between “build 
>> trigger” and “trigger build”  I get confused many times too.
>>
>>  
>>
>> So, if you want that “second job” trigger build of “first job” then you 
>> need to configure a “build trigger” on the “first job” mentioning the 
>> “second job”.
>>
>>  
>>
>> I hope that is what you are looking for.
>>
>>  
>>
>> Cheers,
>>
>> Gianluca.
>>
>>  
>>
>>  
>>
>> *From:* jenkins...@googlegroups.com  *On 
>> Behalf Of *Adharsha sri
>> *Sent:* 17 December 2021 14:10
>> *To:* jenkins...@googlegroups.com
>> *Subject:* Re: Trigger upstream job
>>
>>  
>>
>> Hi, 
>>
>> We created 2 freestyle jobs( first job, second job) and we have mentioned 
>> first job in *build trigger - build after other projects are build( if 
>> build is stable) * in second job configuration. When we click  buildnow 
>> in second job , it need to trigger first job and if it is 
>> successfully completed then the second job should run, but it is not 
>> happening.
>>
>>  
>>
>> Thanks, 
>>
>> Adharsha.
>>
>>  
>>
>>  
>>
>> On Fri, 17 Dec 2021, 7:19 pm ,  wrote:
>>
>> Hi Adharsha,
>>
>> We use this in our pipeline and works:
>>
>>  
>>
>> def job = build([
>> *job*: “Job/name”,
>> *wait*: *true*,
>> *propagate*: 
>> *false*])
>>
>>  
>>
>> What are the errors that you are experience on doing it?
>>
>> Can you add more details?
>>
>>  
>>
>> Cheers,
>>
>> Gianluca.
>>
>>  
>>
>> *From:* jenkins...@googlegroups.com  *On 
>> Behalf Of *Adharsha sri
>> *Sent:* 17 December 2021 13:46
>> *To:* jenkins...@googlegroups.com
>> *Subject:* Trigger upstream job
>>
>>  
>>
>> Hi Team,
>>
>>  
>>
>> Need to trigger the upstream job from the run downstream job.
>>
>>  
>>
>> We are able to trigger the down stream job from upstream job but not in 
>> reverse direction.  Can you please help us.
>>
>>  
>>
>> Requirement:
>>
>>  
>>
>> First job <-- Second job
>>
>>  
>>
>> When I run second job it should trigger upstreamjob (I.e. first job). And 
>> first job should be independent.
>>
>>  
>>
>> Thanks,
>>
>> Adharsha.
>>
>>  
>>
>>  
>>
>> -- 
>> 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/CAJWGB6q%3DZ7c0ei39cuYqqDjYUowBp0A_rk3TGqqrCpQD_LOvbQ%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-use...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/00c401d7f34c%24eebc7070%24cc355150%24%40gmail.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/CAJWGB6rn8ZSsWTGSph3Gkv%2BkkCUHQDykZ1knvhLiOysfU3b3cQ%40mail.gmail.com
>>  
>> 
>> .
>>
>> -- 
>> You received this message because you are 

Re: Declarative Pipeline: Add trigger only on when condition

2021-11-19 Thread 'Björn Pedersen' via Jenkins Users
You can't do it on the triggers level ( the trigger config only can affect 
the next run, as the job is already triggered), but you can wrap the whole 
work in the pipeline in a when, 
so if the  branch is a  userbranch this run is mostly a do-nothing.

Björn

sverr...@gmail.com schrieb am Mittwoch, 27. Oktober 2021 um 13:40:43 UTC+2:

> User branches are like
> origin/username/CICD
> Official branches are origin/CICD og origin/master
>
> All part of the same project.
> CICD branch has a different Declarative Pipeline for CICD release build 
> and deployment.
> Same goes for user branches that are based on this CICD branch.
>
> All other branches have our standard Scripted Pipeline.
> So we have already splitt different pipelines for these.
>
> When all branches based on CICD are building, we don't want to build 
> release and deploy from user branches of it, only the origin/CICD.
> I wanted to avoid username/CICD being automatically triggered and built 
> when origin/master had built. It should only trigger on origin/CICD.
>
> onsdag 27. oktober 2021 kl. 09:25:01 UTC+2 skrev victormar...@gmail.com:
>
>> I'm not sure if I understood correctly what user branches of the CICD 
>> mean in this particular case, can you clarify it?
>> Some other questions:
>> - Are the master and CICD branches part of the same projectA? 
>> - If so, how do users interact with the project?
>>
>> As far as I see the upstream trigger option allows to listen for changes 
>> in some other projects.
>>
>> Will it work if you split two pipelines instead?
>>
>> *Pipeline for the master branch *
>>
>> or even a multibranch pipeline if needed, then you can exclude  the CICD 
>> branch to be built.
>>
>> *Pipeline for the branch CICD*
>>
>> or event a multibranch pipeline if needed, then you can exclude 
>> everything but the CICD branch.
>>
>> triggers {
>>   upstream("projectA/master'")
>> }
>>
>>
>> Cheers
>>
>> On Friday, 22 October 2021 at 11:17:46 UTC+1 sverr...@gmail.com wrote:
>>
>>> We have a branch in projectA called CICD.
>>> This branch we want to be triggered automatically after the master 
>>> branch has built.
>>> However we do not want user branches of the CICD to be triggered 
>>> automatically.
>>>
>>> Is it possible to avoid configuring a trigger if the branch is not CICD?
>>>
>>> This is probably not possible, but would be very useful.
>>>
>>> triggers {
>>>   upstream 'projectA/master'
>>>   when {
>>> branch 'CICD'
>>>   }
>>> }
>>>
>>

-- 
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/11989e22-3aa3-47d4-85c9-b4222c70f060n%40googlegroups.com.


Re: "pending - waiting for next executor" message occurs while executing the job in Jenkins

2021-10-20 Thread 'Björn Pedersen' via Jenkins Users


kuzh...@gmail.com schrieb am Dienstag, 19. Oktober 2021 um 20:14:52 UTC+2:

> I have no jobs available in the queue.I increased the executor 
> counter,still got the same message.
>
>
Hard to tell without more information...
 * what kind of job:  pipeline , freestyle, ???
 * configured labels for nodes
* if pipeline: the pipeline code
 * 
 

> Thanks,
> Poo
>
> On Tue, Oct 19, 2021, 4:22 PM selva vignesh  wrote:
>
>> Hi,
>> All executors are running other Jobs. So, you are getting this error. 
>> Once,  any one of the executors gets available, it will take care your 
>> Queued job 
>> Or, increase the executors count in Manage Jenkins -> Configure System 
>>
>> On Tue, Oct 19, 2021 at 4:15 PM Poonkuzhali Muthiah  
>> wrote:
>>
>>> Hi,
>>>
>>> I am unable to execute any jobs in Jenkins.When I run the job,I am 
>>> getting the following error message 
>>> "pending - waiting for next executor".How can I solve this issue.
>>>
>>>
>>> Thanks,
>>> Poo
>>>
>>> -- 
>>> 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/CAJ5r41VdF3NeWkSanqewTzmfT8RZUVJYr0PO%3DE5Ni6Hvp6PDLA%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-use...@googlegroups.com.
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/CAOVVkpmMxqekjAdcFLD8C-kB4VD-gncQ%3DUJf8e64LtkUvbrGFQ%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/26162a76-57f2-4e8b-bd10-36d1b06b2f13n%40googlegroups.com.


Re: "pending - waiting for next executor" message occurs while executing the job in Jenkins

2021-10-19 Thread 'Björn Pedersen' via Jenkins Users


kuzh...@gmail.com schrieb am Dienstag, 19. Oktober 2021 um 12:45:17 UTC+2:

> Hi,
>
> I am unable to execute any jobs in Jenkins.When I run the job,I am getting 
> the following error message 
> "pending - waiting for next executor".How can I solve this issue.
>

Some more reason why you could get this message:

 - no executors with the requested label up and running
 - on-demand executors not starting or with a long delay or only scheduled 
for e.g. out-of-office times

So check the job which executor it expects and then compare this to the 
available ones.
 

>
> Thanks,
> Poo
>

-- 
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/ed4c8655-38b6-49b3-b4ab-61a68b474b8en%40googlegroups.com.


Re: Pipeline: Nodes and Processes incompatibility?

2021-10-06 Thread 'Björn Pedersen' via Jenkins Users
See https://groups.google.com/g/jenkinsci-users/c/R7AUrb6nq5k

fr...@fritz-elfert.de schrieb am Mittwoch, 6. Oktober 2021 um 16:54:26 
UTC+2:

>
> Hi,
>
> I am looking at the Plugin Manager im my jenkins 2.303.1 installation and 
> it
> shows this warning for the Pipeline: Nodes and Processes plugin:
>
> Warning: The new version of this plugin is marked as incompatible with the 
> installed version. This is usually the case because its behavior changed, 
> or because it uses a different settings format than the installed version. 
> Jobs using this plugin may need to be reconfigured, and/or you may not be 
> able to cleanly revert to the prior version without manually restoring old 
> settings. Consult the plugin release notes for details.
>
> I currently have 2.39 installed and the warning is for 2.40
>
> Despite looking at the obvious place: (github releases in this case) it is 
> unclear to me, what exactly is incompatible.
> Can anybody enlighten me?
>
> Thanks in advance
> -Fritz
>

-- 
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/3db07205-b386-4ccb-9dfe-d94c050cafa8n%40googlegroups.com.


Re: Inserting a Jelly template into a step

2021-09-28 Thread 'Björn Pedersen' via Jenkins Users


Victor Sudakov schrieb am Dienstag, 28. September 2021 um 09:21:26 UTC+2:

> Hello Colleagues, 
>
> Sorry for being dumb. I'm currently using the following simple step: 
>
> post { 
> failure { 
> emailext body: 'Check console output at $BUILD_URL to view the results', 
> subject: ' 
> } 
> } 
>
> If I want to replace this simple oneliner with a Jelly template, where 
> should 
> I insert the ${JELLY_SCRIPT,template="text"} variable? I've tried the 
> following: 
>
> emailext body: '${JELLY_SCRIPT,template="text"}', subject: ' 
>
>
did you mena template="html" ?
 

> But it resulted in a very laconic mail body: 
>
>
Seems like that is correct for the text template. Many things in the output 
will only be there if you also have the correct 
steps in your pipeline ( cobertura coverage, junit results). And as some of 
those are outdated you probably need to
 write your own template to use the newer replacement versions.

Björn

-- 
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/b264603a-f0ac-4940-a79e-5883759ef10fn%40googlegroups.com.


Re: Any way to construct a url to a particular file in the jenkins workspace?

2021-09-27 Thread 'Björn Pedersen' via Jenkins Users



>
> That "our local path" thing is not clear to me. What exactly would that 
> be?  If the file I create is in the root directory of the workspace , would 
> that "local path" be empty?
>

Correct. The pathes you specify are relative to the workspace part. To 
check just compare the 

-- 
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/59fa524c-fdb9-4727-b497-f0e498c1bf80n%40googlegroups.com.


Re: Pull changes when a tag is created

2021-09-27 Thread 'Björn Pedersen' via Jenkins Users


>
>> On Wednesday, September 22, 2021 at 11:50:30 AM UTC-8 
>> jayarama...@gmail.com wrote:
>>
>>> Hello,
>>>
>>> I wanted to trigger a Jenkins build when a new tag is created but I'm 
>>> not having any luck with it. 
>>>
>>> Just to be sure I mentioned it, I don't have access to modify the repo 
>>> since it's a public repo.
>>>
>>> The following configuration is what I used in the "Git" Source Code 
>>> Management
>>> Repo URL: https://github.com/apache/tomcat.git
>>> Refspec: +refs/tags/8.5.*:refs/remotes/origin/tags/8.5.*
>>> Branch Specifier: **/tags/**
>>> Build Trigger: Poll SCM (with no schedule)
>>>
>>> Is there something I'm doing wrong?
>>>
>>> I can't do WebHooks which is unfortunate I thin
>>>
>>

If you can't use webhooks than you need a schedule ( otherwise the polling 
will never run).

Björn 

-- 
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/9e203c45-8645-4bab-8eda-0ef6457cf7b6n%40googlegroups.com.


Re: Any way to construct a url to a particular file in the jenkins workspace?

2021-09-22 Thread 'Björn Pedersen' via Jenkins Users


>
> I'm not familiar with the archive process. If you could provide me some 
> quick links for information, that would be useful. I'll also ask our 
> internal ops team.
>
>

Archiving is not something  special, it's a standard feature.
in a scripted pipeline: 

archiveArtifacts artifacts: '**/*.log' 
(just use the script builder for more help)

link to:
$BUILD_URL/artifact//

Björn

-- 
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/0afebe05-f291-4271-ac72-7f98f26637f3n%40googlegroups.com.


Re: Any way to construct a url to a particular file in the jenkins workspace?

2021-09-22 Thread 'Björn Pedersen' via Jenkins Users


db...@cloudbees.com schrieb am Mittwoch, 22. September 2021 um 14:54:48 
UTC+2:

> On Mon, Sep 13, 2021 at 5:49 PM Jerome Godbout  
> wrote:
>
>> Humm, that would be hard and security unwise. The executing node path 
>> aren't available to the web.
>
>
> They are in the case of workspace files (to users with appropriate 
> permissions).
>
> I think the problem is that it's difficult to obtain the pipeline node ID 
> for the `node` step allocating the workspace.
>
> Between the BUILD_URL and WORKSPACE (the prefix of the path to remove), 
> the rest should be known.
>

I the another problem that is more important (at least in general): The 
workspace is not persisted as part of the job, instead it
 may well get reused  and/or cleaned once the job is finished. So clicking 
the link on an older job may well get you the file from 
a newer run. That's why I really recommend to just archive this file as 
artifact and use the artifact link( which is stable and easier to construct)
instead.
Björn
 

-- 
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/d26036f1-fdeb-4b48-a080-d60098bd0f4an%40googlegroups.com.


Re: Jenkins workspace with @2

2021-09-20 Thread 'Björn Pedersen' via Jenkins Users
Hi,

generally you should always consider these workspaces as temporary and 
managed by jenkins. If you need to put files (persistent) in defined places 
you should do this by explicitly copying  the files (or e.g. use one of the 
artifact publisher plugins).


And check  the ws step docs:
  
A workspace is automatically allocated for you with the node step, or you 
can get an alternate workspace with this ws step, but by default the 
location is chosen automatically. (Something like 
AGENT_ROOT/workspace/JOB_NAME@2.)

You can instead specify a path here and that workspace will be locked 
instead. (The path may be relative to the build agent root, or absolute.)

If concurrent builds ask for the same workspace, a directory with a suffix 
such as @2 may be locked instead. Currently there is no option to wait to 
lock the exact directory requested; if you need to enforce that behavior, 
you can either fail (error) when pwd indicates that you got a different 
directory, or you may enforce serial execution of this part of the build by 
some other means such as stage name: '…', concurrency: 1.

If you do not care about locking, just use the dir step to change current 
directory.

   


lalchan...@gmail.com schrieb am Samstag, 18. September 2021 um 19:18:28 
UTC+2:

> Yes now  I have added this but still I am noticing workspace getting 
> created with @2 
>
>
>
>
> On Sat, 18 Sep, 2021, 22:38 geoffroy...@gmail.com,  
> wrote:
>
>> Have you tried https://www.jenkins.io/doc/book/pipeline/syntax/#options
>>
>> options { disableConcurrentBuilds() }
>>
>> On Friday, 17 September 2021 at 18:35:02 UTC+2 lalchan...@gmail.com 
>> wrote:
>>
>>> I want default workspace should be working instead of @2. How can I 
>>> achieve that.
>>>
>>> Thanks,
>>> Lalchand
>>>
>>> On Fri, 17 Sep, 2021, 19:14 'Dirk Heinrichs' via Jenkins Users, <
>>> jenkins...@googlegroups.com> wrote:
>>>
 Am Freitag, dem 17.09.2021 um 01:14 -0700 schrieb Lalchand Rajak:

 I  have a job running in Jenkins and It's creating a workspace with a 
 job name@2 or sometimes with @3. Can any one help why this is happening?.


 Because you have multiple builds of that job running at the same time. 
 You don't want them to build in the same workspace, do you?

 Bye...

 Dirk

 -- 

 *Dirk Heinrichs*
 Senior Systems Engineer, Delivery Pipeline
 OpenText ™ Discovery | Recommind
 *Phone*: +49 2226 15966 18 <+49%202226%201596618>
 *Email*: dhei...@opentext.com
 *Website*: www.recommind.de
 Recommind GmbH, Von-Liebig-Straße 1, 53359 Rheinbach
 Vertretungsberechtigte Geschäftsführer Gordon Davies, Madhu 
 Ranganathan, Christian Waida, Registergericht Amtsgericht Bonn, 
 Registernummer HRB 10646
 This e-mail may contain confidential and/or privileged information. If 
 you are not the intended recipient (or have received this e-mail in error) 
 please notify the sender immediately and destroy this e-mail. Any 
 unauthorized copying, disclosure or distribution of the material in this 
 e-mail is strictly forbidden
 Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte 
 Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail 
 irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und 
 vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte 
 Weitergabe dieser Mail sind nicht gestattet.

 -- 
 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/d1148e47a9d8cdde0f93667657b5a509e99e.camel%40opentext.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/b841e13c-859b-4b9b-9838-01a5b8065870n%40googlegroups.com
>>  
>> 
>> .
>>
>

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


Re: Any way to construct a url to a particular file in the jenkins workspace?

2021-09-13 Thread 'Björn Pedersen' via Jenkins Users
Hi,

no, not really. Especially as  workspaces typically are reused between jobs 
such an URL would be at leas open to surprise.  Best practice is to archive 
such files (log output, generated files. ) as  artifacts to get 
persistence. 

Björn

davidmic...@gmail.com schrieb am Freitag, 10. September 2021 um 22:09:36 
UTC+2:

> I do notice that my build has a "BUILD_URL" var in the environment, so 
> that gives me the "prefix" of the url, but the url to the file in the 
> workspace has pieces like the following after the BUILD_URL value: 
> "/execution/node/22/ws/". I don't see anything else in the environment that 
> can help me construct that part of the url.
>
> On Friday, September 10, 2021 at 9:22:16 AM UTC-7 David Karr wrote:
>
>> When a Jenkins build completes, I can navigate to "Workspaces" to 
>> manually inspect files in the workspace.  While I'm navigating that tree, 
>> and viewing specific files, I can see that the current browser url goes 
>> directly to that point in the tree, and to the specific file I am viewing.
>>
>> Is there a practical way in a Jenkins scripted pipeline, to CONSTRUCT a 
>> url to a file in the workspace so I can print it out in the log, to enable 
>> a single click to get to a particular file?
>>
>

-- 
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/3124e21e-9b34-4359-9e83-d0401ac64ec0n%40googlegroups.com.


Re: NodeProperty extension behaves differently with Freestyle than Pipeline job

2021-09-07 Thread 'Björn Pedersen' via Jenkins Users
(Note: better suited jenkinsci-dev list)

Node and workspace handling differs quite a lot between freestyle and 
pipeline jobs. In a single pipeline you can create many nodes (node block) 
and even works spaces (ws blocks).
So this is  expected...

Björn

and...@hammar.net schrieb am Dienstag, 7. September 2021 um 12:42:59 UTC+2:

> Hi,
>
> I'm trying to build an extension that would automatically remove/delete 
> the workspace when leaving a node. It seems possible to do this through a 
> NodeProperty extension where I create an Environment object that would 
> handle this.
>
> However, trying this I see different behavior in e.g. a Freestyle build 
> than in a pipeline build. In the Freestyle build it works, but in the 
> pipeline build the setUp() method is not called. Is this difference 
> expected?
>
> The extension can be found at [1].
>
> /Anders
>
> [1] https://github.com/andham/jenkins-nodeproperty-plugin
>

-- 
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/3cf21049-8775-4436-abbd-a752406bba08n%40googlegroups.com.


Re: Can't run shell script in docker container

2021-09-03 Thread 'Björn Pedersen' via Jenkins Users
How are you starting the container and run the script?  From the locations 
it looks like  a sh step in a pipeline. 
Then you should  not mount jenkins_home or temp that way.  
Instead use a docker.image.inside step to  run the script. It will  do the  
correct mounting. 
(/tmp should mount /var/jenkins_home/workspace/Production/Test2@tmp, not 
the host tmp ,and the container should also mount
the workspace ( /var/jenkins_home/workspace/Production/Test2[@n]) only, not 
the full jenkins home.)

jerome.god...@gmail.com schrieb am Donnerstag, 2. September 2021 um 
15:18:02 UTC+2:

> Are you sure the mount of tmp did work and not superseed by another 
> default mount there?
>
> Maybe try to touch a new file from the docker and see if it show up into 
> the original tmp folder. If so, it mean you might have permission problems 
> instead. Make sure to allow rw for everyone on the file before.
>
> On Thursday, September 2, 2021 at 7:18:50 AM UTC-4 il...@icandeliver.ru 
> wrote:
>
>> Good day!
>>
>> I am trying to run a shell script in a docker container.  The script is 
>> created on the host in the folder: 
>> */var/jenkins_home/workspace/Production/Test2@tmp*
>>
>> The container by default is starts with the following volumes:
>> *--volume /var/jenkins_home:/var/jenkins_home:rw --volume /tmp:/tmp:rw*
>>
>> But it is launched in the container from the folder:
>>
>> */bin/sh: can't open '/tmp/jenkins15846770116304196347.sh': No such file 
>> or directory Build step 'Execute shell' marked build as failure*
>>
>> How to fix that issue?
>>
>

-- 
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/5e6ab623-88eb-4841-a7f5-e474515cde54n%40googlegroups.com.


Re: Why does my Jenkins not run a .exe file?

2021-08-31 Thread 'Björn Pedersen' via Jenkins Users
 I would consider using powershell instead of bat for such jenkins tasks, 
then Start-Job 

 should 
do the trick ( you will need to also call Stop-Job once you are done of 
course).

christop...@googlemail.com schrieb am Dienstag, 31. August 2021 um 10:42:03 
UTC+2:

> In my opinion "call" is not the right statement to call an exe. Can you 
> try it with a start with the proper arguments?
> Regards,
> Christoph
>
> slide schrieb am Donnerstag, 19. August 2021 um 17:28:44 UTC+2:
>
>> Does the application try and interact with the desktop? If you are 
>> running the agent/jenkins as a Windows service, it will not be able to 
>> interact with the desktop by default. You need to search for "services 
>> interact desktop windows" to find information on how to enable it.
>>
>> On Thu, Aug 19, 2021 at 8:20 AM Mahmoud Beltagy  
>> wrote:
>>
>>> It is important for my build to open this exe, without it the build 
>>> process will fail, so the issue is not continuing the process.
>>> I want jenkins to be able to open an external exe to use it in the build 
>>> process
>>>
>>> On Wednesday, August 18, 2021 at 4:01:27 PM UTC+2 ice...@googlemail.com 
>>> wrote:
>>>
 mahmoud...@ejad.com.eg schrieb am Mittwoch, 18. August 2021 um 
 15:14:13 UTC+2:

> I have the same issue here.
> I have a .bat file named bat *RunUSBRedirector.bat* that only has one 
> line
>
> *call "C:\Program Files\USB Redirector Client\usbredirectorlt.exe"*
> this line should start the application USB Redirector Client
> when I invoke this .bat file in the cmd it behaves as expected, but 
> when I try to run it in jenkins [bat """RunUSBRedirector.bat"""]  it gets 
> stuck.
> I tried the mentioned points:
> -Run another exe (calc.exe for example) it worked, but when I tried 
> another exe that I installed a few months ago it did not work
> -using cmd /c does not change anything
> -I get an error when I add a typo to the name of the exe
> -I don't think the program waits for stdin, and I don't know how to 
> close it (NOTE: cmd window does not show)
>

 Yes,  that is expected. You can only usefully commands that finish at 
 some point in time and only then the next command will be executed. 
 If the program runs forever then it looks like it is stuck (but it is 
 just  waiting for the program to finish).  
 See https://superuser.com/a/341603 for how send a program into 
 background on windows.  
 You should also have some way to stop the program again before your  
 jenkins job exits
  

> -the web interface does not get stuck
>
 -- 
>>> 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/9962af5c-e61e-455a-bb9b-96f7cfb2ab21n%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>>
>>
>> -- 
>> Website: http://earl-of-code.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/2c18fd43-f6fd-4847-a936-cf2c4d8d5c32n%40googlegroups.com.


Re: Why does my Jenkins not run a .exe file?

2021-08-18 Thread 'Björn Pedersen' via Jenkins Users


mahmoud...@ejad.com.eg schrieb am Mittwoch, 18. August 2021 um 15:14:13 
UTC+2:

> I have the same issue here.
> I have a .bat file named bat *RunUSBRedirector.bat* that only has one line
>
> *call "C:\Program Files\USB Redirector Client\usbredirectorlt.exe"*
> this line should start the application USB Redirector Client
> when I invoke this .bat file in the cmd it behaves as expected, but when I 
> try to run it in jenkins [bat """RunUSBRedirector.bat"""]  it gets stuck.
> I tried the mentioned points:
> -Run another exe (calc.exe for example) it worked, but when I tried 
> another exe that I installed a few months ago it did not work
> -using cmd /c does not change anything
> -I get an error when I add a typo to the name of the exe
> -I don't think the program waits for stdin, and I don't know how to close 
> it (NOTE: cmd window does not show)
>

Yes,  that is expected. You can only usefully commands that finish at some 
point in time and only then the next command will be executed. 
If the program runs forever then it looks like it is stuck (but it is just  
waiting for the program to finish).  
See https://superuser.com/a/341603 for how send a program into background 
on windows.  
You should also have some way to stop the program again before your  
jenkins job exits
 

> -the web interface does not get stuck
>

-- 
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/2bbdb7a0-8851-448b-9550-ea1ea63d3603n%40googlegroups.com.


Re: Trouble using JenkinsRule with PluginManager

2021-08-06 Thread 'Björn Pedersen' via Jenkins Users
And see 
also 
https://javadoc.jenkins.io/component/jenkins-test-harness/org/jvnet/hudson/test/HudsonTestCase.html#useLocalPluginManager

Björn Pedersen schrieb am Freitag, 6. August 2021 um 09:38:13 UTC+2:

> And take a look at 
> https://javadoc.jenkins.io/component/jenkins-test-harness/org/jvnet/hudson/test/RestartableJenkinsRule.html
>  
> , especially the info about 
>  UnitTestSupportingPluginManager. 
>
> Björn
>
>
> Björn Pedersen schrieb am Freitag, 6. August 2021 um 09:32:14 UTC+2:
>
>> I guess this question is better suited for 
>> https://groups.google.com/g/jenkinsci-dev
>>
>> matthi...@outlook.com schrieb am Donnerstag, 5. August 2021 um 16:48:48 
>> UTC+2:
>>
>>> Thanks for the reply. It looks like your repo is similar to 
>>> https://github.com/sheehan/job-dsl-gradle-example/, which is the 
>>> example that our repo is based on as well. We've got Specifications that 
>>> test the job DSL syntax and other job configuration stuff. And I see how 
>>> the resolveTestPlugins task in build.gradle saves plugins to the 
>>> build/resources/test/test-dependencies folder that the Jenkins test harness 
>>> will look in to get the plugins with which to load the in-memory Jenkins 
>>> instances. 
>>>
>>> What I want to do is load those in-memory Jenkins instances spun up by 
>>> the Jenkins test harness with different plugins, depending on the 
>>> Specification being run. So for most Specifications, I'll use one set of 
>>> plugins, but for another set of Specifications, I'd like to use another...
>>>
>>> I thought that `new JenkinsRule().with(MyPluginManager.INSTANCE)` or 
>>> something like that would solve this issue for me, but I'm having trouble 
>>> with it. I'm seeking help on how to get this to work. 
>>>
>>> I've updated my StackOverflow question with a link to a GitHub repo that 
>>> reproduces the problem I'm seeing: 
>>> https://github.com/matthiasdenu/plugin-manager-bug/tree/main 
>>>
>>> Help is appreciated!
>>>
>>> On Wednesday, June 30, 2021 at 12:15:42 PM UTC-4 kuisat...@gmail.com 
>>> wrote:
>>>
 We do not use Spock, but we have a process to test jobDSL definitions 
 before applying changes see 
 https://github.com/elastic/apm-pipeline-library/tree/master/.ci/jobDSL 
 it test that the syntax is correct and test that you can create the job.
 Probably the class that helps you is 
 https://github.com/elastic/apm-pipeline-library/blob/master/.ci/jobDSL/src/test/groovy/JobScriptsSpec.groovy
  
 , also it is really tricky to configure the plugins you need on 
 https://github.com/elastic/apm-pipeline-library/blob/master/.ci/jobDSL/build.gradle#L29-L68

 El miércoles, 30 de junio de 2021 a las 16:33:56 UTC+2, 
 matthi...@outlook.com escribió:

> Hi, I'm trying to use a different set of plugins for different Spock 
> Specifications. I've posted a more detail question here: 
> https://stackoverflow.com/questions/68196423/trouble-using-a-base-spock-specification-and-jenkinsrule-with-pluginmanager
>  
> I'm hoping that someone might be able to provide some insight. Thank you. 



-- 
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/76ef10c3-148b-4af2-b92a-3ebf40029afen%40googlegroups.com.


Re: Trouble using JenkinsRule with PluginManager

2021-08-06 Thread 'Björn Pedersen' via Jenkins Users
And take a look 
at 
https://javadoc.jenkins.io/component/jenkins-test-harness/org/jvnet/hudson/test/RestartableJenkinsRule.html
 
, especially the info about 
 UnitTestSupportingPluginManager. 

Björn


Björn Pedersen schrieb am Freitag, 6. August 2021 um 09:32:14 UTC+2:

> I guess this question is better suited for 
> https://groups.google.com/g/jenkinsci-dev
>
> matthi...@outlook.com schrieb am Donnerstag, 5. August 2021 um 16:48:48 
> UTC+2:
>
>> Thanks for the reply. It looks like your repo is similar to 
>> https://github.com/sheehan/job-dsl-gradle-example/, which is the example 
>> that our repo is based on as well. We've got Specifications that test the 
>> job DSL syntax and other job configuration stuff. And I see how the 
>> resolveTestPlugins task in build.gradle saves plugins to the 
>> build/resources/test/test-dependencies folder that the Jenkins test harness 
>> will look in to get the plugins with which to load the in-memory Jenkins 
>> instances. 
>>
>> What I want to do is load those in-memory Jenkins instances spun up by 
>> the Jenkins test harness with different plugins, depending on the 
>> Specification being run. So for most Specifications, I'll use one set of 
>> plugins, but for another set of Specifications, I'd like to use another...
>>
>> I thought that `new JenkinsRule().with(MyPluginManager.INSTANCE)` or 
>> something like that would solve this issue for me, but I'm having trouble 
>> with it. I'm seeking help on how to get this to work. 
>>
>> I've updated my StackOverflow question with a link to a GitHub repo that 
>> reproduces the problem I'm seeing: 
>> https://github.com/matthiasdenu/plugin-manager-bug/tree/main 
>>
>> Help is appreciated!
>>
>> On Wednesday, June 30, 2021 at 12:15:42 PM UTC-4 kuisat...@gmail.com 
>> wrote:
>>
>>> We do not use Spock, but we have a process to test jobDSL definitions 
>>> before applying changes see 
>>> https://github.com/elastic/apm-pipeline-library/tree/master/.ci/jobDSL 
>>> it test that the syntax is correct and test that you can create the job.
>>> Probably the class that helps you is 
>>> https://github.com/elastic/apm-pipeline-library/blob/master/.ci/jobDSL/src/test/groovy/JobScriptsSpec.groovy
>>>  
>>> , also it is really tricky to configure the plugins you need on 
>>> https://github.com/elastic/apm-pipeline-library/blob/master/.ci/jobDSL/build.gradle#L29-L68
>>>
>>> El miércoles, 30 de junio de 2021 a las 16:33:56 UTC+2, 
>>> matthi...@outlook.com escribió:
>>>
 Hi, I'm trying to use a different set of plugins for different Spock 
 Specifications. I've posted a more detail question here: 
 https://stackoverflow.com/questions/68196423/trouble-using-a-base-spock-specification-and-jenkinsrule-with-pluginmanager
  
 I'm hoping that someone might be able to provide some insight. Thank you. 
>>>
>>>

-- 
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/aa2c6530-877f-46d0-84c5-772cbc088bf1n%40googlegroups.com.


Re: Trouble using JenkinsRule with PluginManager

2021-08-06 Thread 'Björn Pedersen' via Jenkins Users
I guess this question is better suited 
for https://groups.google.com/g/jenkinsci-dev

matthi...@outlook.com schrieb am Donnerstag, 5. August 2021 um 16:48:48 
UTC+2:

> Thanks for the reply. It looks like your repo is similar to 
> https://github.com/sheehan/job-dsl-gradle-example/, which is the example 
> that our repo is based on as well. We've got Specifications that test the 
> job DSL syntax and other job configuration stuff. And I see how the 
> resolveTestPlugins task in build.gradle saves plugins to the 
> build/resources/test/test-dependencies folder that the Jenkins test harness 
> will look in to get the plugins with which to load the in-memory Jenkins 
> instances. 
>
> What I want to do is load those in-memory Jenkins instances spun up by the 
> Jenkins test harness with different plugins, depending on the Specification 
> being run. So for most Specifications, I'll use one set of plugins, but for 
> another set of Specifications, I'd like to use another...
>
> I thought that `new JenkinsRule().with(MyPluginManager.INSTANCE)` or 
> something like that would solve this issue for me, but I'm having trouble 
> with it. I'm seeking help on how to get this to work. 
>
> I've updated my StackOverflow question with a link to a GitHub repo that 
> reproduces the problem I'm seeing: 
> https://github.com/matthiasdenu/plugin-manager-bug/tree/main 
>
> Help is appreciated!
>
> On Wednesday, June 30, 2021 at 12:15:42 PM UTC-4 kuisat...@gmail.com 
> wrote:
>
>> We do not use Spock, but we have a process to test jobDSL definitions 
>> before applying changes see 
>> https://github.com/elastic/apm-pipeline-library/tree/master/.ci/jobDSL 
>> it test that the syntax is correct and test that you can create the job.
>> Probably the class that helps you is 
>> https://github.com/elastic/apm-pipeline-library/blob/master/.ci/jobDSL/src/test/groovy/JobScriptsSpec.groovy
>>  
>> , also it is really tricky to configure the plugins you need on 
>> https://github.com/elastic/apm-pipeline-library/blob/master/.ci/jobDSL/build.gradle#L29-L68
>>
>> El miércoles, 30 de junio de 2021 a las 16:33:56 UTC+2, 
>> matthi...@outlook.com escribió:
>>
>>> Hi, I'm trying to use a different set of plugins for different Spock 
>>> Specifications. I've posted a more detail question here: 
>>> https://stackoverflow.com/questions/68196423/trouble-using-a-base-spock-specification-and-jenkinsrule-with-pluginmanager
>>>  
>>> I'm hoping that someone might be able to provide some insight. Thank you. 
>>
>>

-- 
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/5130cc41-fefc-4b04-a9a8-2c7838f5a57cn%40googlegroups.com.


Re: Migrate jobs to pipeline "in-place"?

2021-08-04 Thread 'Björn Pedersen' via Jenkins Users
As you would need to delete the old job before you can create a new job 
with the name, no. 

I would  recommend to create a new job with a nice version (e.g. jobnameV2 
) in parallel to the old job, then disable (not delete! ) the old job.

Björn

sl...@dresearch-fe.de schrieb am Mittwoch, 4. August 2021 um 13:46:14 UTC+2:

>
> We like to migrate some "Free-Style"-projects to pipelines.
>
> Is it possible to do this "in place" (i.e. in the same job)? The 
> background is that we do not want to lose the history and links to other 
> jobs.
>
>

-- 
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/4a4c85b9-b953-4d44-85d4-c9c548c382d1n%40googlegroups.com.


Re: multithreading inside cleanup step

2021-07-22 Thread 'Björn Pedersen' via Jenkins Users
Take a look at the end of your stackoverflow link:
 You can use parallel inside a script block even in a post block.
Just  remember that inside a script block you need to use the scripted 
syntax, not  the descriptive syntax.


omr...@gmail.com schrieb am Mittwoch, 21. Juli 2021 um 15:54:27 UTC+2:

> I am building to 2 different environments in the same pipeline and I want 
> to make the cleanup for both environments in parallel.
>
> As I understood, parallel does not work inside the post step: post step 
> parallel 
> 
> .
>
> Any suggestions? Example of my code:
> post { 
>   always { 
>  script{ 
>  cleanup(env1) 
>  cleanup(env2) 
>   }
>} 
> } 
>
>  def cleanup(env) 
> { 
> withEnv(env) 
> { 
>  sh "./cleanup.py" 
>  } 
> }  
>

-- 
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/b7b96911-0b82-4e44-8234-a2feae2dc458n%40googlegroups.com.


Re: credentials-binding-plugin and private key files

2021-06-22 Thread 'Björn Pedersen' via Jenkins Users
This message has been introduced 
by https://github.com/jenkinsci/credentials-binding-plugin/pull/132 (so it 
is only related to the credentials-binding -plugin version, not the core). 

andreas.ch...@gmail.com schrieb am Dienstag, 22. Juni 2021 um 08:19:20 
UTC+2:

> Anyone else noticed this? I just updated my Jenkins to 2.289.1 and some of 
> my build that use a private key file for SSH access fail like this 
> (complete stacktrace at bottom):
> FATAL: Cannot use the same key in both secretValues and publicValues
>
> Turns out that I got rid of the message if I edited my secret and added 
> that the username should be a secret. But I don't understand why, and I 
> think the error message is extremely useless since I couldn't get any 
> diagnostic information from it...
>
> But, I hope it might help anyone else googling the exception message.
> /Andreas 
>
> *12:57:17* FATAL: Cannot use the same key in both secretValues and 
> publicValues 
> *12:57:17* java.lang.IllegalArgumentException: Cannot use the same key in 
> both secretValues and publicValues 
> *12:57:17* at 
> org.jenkinsci.plugins.credentialsbinding.MultiBinding$MultiEnvironment.(MultiBinding.java:101)
>  
> *12:57:17* at 
> org.jenkinsci.plugins.credentialsbinding.impl.SSHUserPrivateKeyBinding.bind(SSHUserPrivateKeyBinding.java:120)
>  
> *12:57:17* at 
> org.jenkinsci.plugins.credentialsbinding.impl.SecretBuildWrapper.setUp(SecretBuildWrapper.java:89)
>  
> *12:57:17* at hudson.model.Build$BuildExecution.doRun(Build.java:157) 
> *12:57:17* at 
> hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:513) 
> *12:57:17* at hudson.model.Run.execute(Run.java:1906) 
> *12:57:17* at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) 
> *12:57:17* at 
> hudson.model.ResourceController.execute(ResourceController.java:97) 
> *12:57:17* at hudson.model.Executor.run(Executor.java:429) 
> *12:57:23* Finished: FAILURE
>
>

-- 
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/02dcde6f-2cf8-47df-8322-7a0743989d30n%40googlegroups.com.


Re: Environment variable "sometimes" not expanded as "Repository URL"

2021-06-09 Thread 'Björn Pedersen' via Jenkins Users
> git config --get remote.${GerritSlave}.url # timeout=10

FATAL: hudson.plugins.git.GitException: Failed to fetch from ${GerritSlave}

This  seems to indicate the ${GerritSlave} is used in the wrong field (the 
'name' field) . It should ever be used in the repo url field.

Björn

mj1414...@gmail.com schrieb am Dienstag, 8. Juni 2021 um 18:59:16 UTC+2:

> Hello,
>
> we’re running Jenkins 2.277.4 on RH7 using OpenJDK11 (and no container) + 
> Git plugin 4.7.1
>
> In “Global properties” of the Jenkins configuration, we’ve defined a 
> shell variable:
>
> GerritSlave
>
> ssh://h...@gerrit-com:29418/repo/path
>
>  
>
> Later on, in the job configuration we use this in 
>
> Source Code Management
>
>   Git
>
> Repository URL
>
>${GerritSlave}
>
>  
>
> Having the job triggered by polling.
>
>  Now we had to find, that we see jobs not starting and in “Git polling 
> log” we find:
>
> 
>
> Started on Jun 8, 2021, 5:26:00 PM
>
> Polling SCM changes on master
>
> Using strategy: Default
>
> [poll] Last Built Revision: Revision 
> 5cb005655e96b87a21df36a5c1dad1ebdb925854 
> (refs/remotes/origin/branches/maintenance/PSint)
>
> The recommended git tool is: NONE
>
> using credential 50da578b-178c-4cba-b103-91c74f6522ed
>
> > git rev-parse --resolve-git-dir 
> /var/fpwork/WS/PHY_TX--LF--PSint--buildTrigger/PHY_TX/.git # timeout=10
>
> Fetching changes from the remote Git repositories
>
> > git config remote.origin.url ${GerritSlave} # timeout=10
>
> Cleaning workspace
>
> > git rev-parse --verify HEAD # timeout=10
>
> Resetting working tree
>
> > git reset --hard # timeout=10
>
> > git clean -fdx # timeout=10
>
> Fetching upstream changes from ${GerritSlave}
>
> > git --version # timeout=10
>
> > git --version # 'git version 2.30.0'
>
> > git config --get remote.${GerritSlave}.url # timeout=10
>
> FATAL: hudson.plugins.git.GitException: Failed to fetch from ${GerritSlave}
>
> hudson.plugins.git.GitException: Command "git config --get 
> remote.${GerritSlave}.url" returned status code 1:
>
> stdout: 
>
> stderr: 
>
>   at 
> org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2661)
>
>  ---
>
> So it looks like the variable didn’t get expanded and then the polling 
> fails.
>
> If this happens, it seems the polling gets stuck in this situation.
>
>  
>
> If I now trigger the job once manually (“Build with parameters”), the GIT 
> polling will work: The variable gets expanded as expected, the job gets 
> triggered if needed.
>
> But it seems eventually, it gets stuck in the same way again.
>
> I’m not sure, but it seems the problem started with updating the Jenkins 
> core (from 2.263.4 to 2.277.4) and the GIT plugin.
>
> Any ideas how to debug – or even better solve – this problem ?
>
> Anyone seeing similar issues, maybe since updating ?
>
> Regards
>
> Martin
>

-- 
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/abf4439f-c546-4366-beed-7aa45cd9e889n%40googlegroups.com.


Re: Jenkins upgrade from 2.250 to 2.275

2021-05-31 Thread 'Björn Pedersen' via Jenkins Users
BTW, if you don't want to do too frequent updates (upgrade each week and 
check for all changes each time), I would consider switching to the LTS 
series (2.277.1 in your case).
Then such changes would be easier to find in the LTS changelog. 

Björn

Björn Pedersen schrieb am Montag, 31. Mai 2021 um 08:47:46 UTC+2:

> Hi,
>
> it seems you  did not upgrade all plugins as well. These effects are 
> caused by the tables-to-div migrations.
>
> See https://www.jenkins.io/doc/developer/views/table-to-div-migration/ 
> for more details...
>
> Björn
>
> s.p...@gmail.com schrieb am Montag, 31. Mai 2021 um 02:52:14 UTC+2:
>
>> After I upgraded Jenkins from 2.250 to 2.275, I noticed that the UI for 
>> the Jobs configuration looks different. The section for Source Code 
>> Management/Build Triggers/Build Environment/build/Post-build actions are 
>> missing at the top of the job configuration page and I see a couple of 
>> Artifactory configuration sections(tabs). Also, the SSH 
>> settings/configuration that we set up for each job are missing. Not sure 
>> how to turn off the Artifactory configuration and restore the SSH settings. 
>> Please the attached screenshots. Please help. TIA
>> Jenkins is running on Windows 2012R2 server.
>>
>>
>>

-- 
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/34578c37-a274-42cd-83ab-8dcc2d023939n%40googlegroups.com.


Re: Jenkins upgrade from 2.250 to 2.275

2021-05-31 Thread 'Björn Pedersen' via Jenkins Users
Hi,

it seems you  did not upgrade all plugins as well. These effects are caused 
by the tables-to-div migrations.

See https://www.jenkins.io/doc/developer/views/table-to-div-migration/ for 
more details...

Björn

s.p...@gmail.com schrieb am Montag, 31. Mai 2021 um 02:52:14 UTC+2:

> After I upgraded Jenkins from 2.250 to 2.275, I noticed that the UI for 
> the Jobs configuration looks different. The section for Source Code 
> Management/Build Triggers/Build Environment/build/Post-build actions are 
> missing at the top of the job configuration page and I see a couple of 
> Artifactory configuration sections(tabs). Also, the SSH 
> settings/configuration that we set up for each job are missing. Not sure 
> how to turn off the Artifactory configuration and restore the SSH settings. 
> Please the attached screenshots. Please help. TIA
> Jenkins is running on Windows 2012R2 server.
>
>
>

-- 
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/e82b848a-f9a0-4756-8424-e0205d881037n%40googlegroups.com.


Re: Issue in pipeline step of jenkinsfile

2021-05-12 Thread 'Björn Pedersen' via Jenkins Users
You need to add an intermediate var in your first loop and use this in the 
sh step

sprat...@gmail.com schrieb am Dienstag, 11. Mai 2021 um 14:59:56 UTC+2:

> Hey Devin,
> Sorry for the late reply , I was down with covid for some time.
> the code that you have given i tried and it works , but how to handle the 
> string parameters ?
> some string parameters which I am assigning they are also interfering with 
> each other
>
>
> On Fri, Apr 16, 2021 at 9:07 PM Devin Nusbaum  
> wrote:
>
>> This is a classic issue that a lot of people run into in various 
>> programming languages. 
>> https://groovyconsole.appspot.com/script/5078409050849280 shows the same 
>> problem and one way to fix it (click "edit in console" and then you can 
>> execute the script). This kind of issue is why in Java, anonymous classes 
>> and lambda expressions can only reference variables that are final or 
>> effectively final.
>>
>> On Apr 16, 2021, at 11:16, spratap singh  wrote:
>>
>> registeries = [1,2,3,4] 
>>  Map tasks = [:]
>>  for (j=0;j<=registeries.size();j++) 
>> { 
>>  tasks["Code ${j}"] = { -> sh "touch ${j}" }
>>  } 
>>  parallel(tasks) 
>>  sh "ls -lrt"
>>
>> Above code should create files 0,1,2,3,4,5
>>
>> but the last line ls -lrt only prints 5 which means it is only taking the 
>> last iteration value in all values of map tasks
>>
>> Can anyone tell what I am doing wrong here ?
>>
>> -- 
>> 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/bfde4364-d93d-4b7a-9ff6-7b2e7bd3c7a2n%40googlegroups.com
>>  
>> 
>> .
>>
>>
>> -- 
>>
> 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/ao0SUF9L0H4/unsubscribe
>> .
>> To unsubscribe from this group and all its topics, send an email to 
>> jenkinsci-use...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/FABC5220-69E1-449A-AA08-5C0BA770D025%40cloudbees.com
>>  
>> 
>> .
>>
>
>
> -- 
> Shashipratap Singh
>

-- 
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/6b615e22-89c6-4cf5-929f-d536e22fbb6an%40googlegroups.com.


Re: Jenkins user is no member of docker group

2021-04-30 Thread 'Björn Pedersen' via Jenkins Users
Has the slave been restarted after setting the groups? On unix the groups 
are only refreshed on login.

chris@gmail.com schrieb am Donnerstag, 29. April 2021 um 14:23:58 UTC+2:

> Dear all,
>
> I have a jenkins slave running on linux (jenkins version 2.249.2). The 
> strange thing is that when I log into this slave via ssh using the jenkins 
> account I can see (using the groups command) that 'jenkins' is member of 
> some groups, including the docker group. However, when I put an "sh 
> 'groups' "line in the Jenkinsfile this user jenkins is not a member of any 
> group besides the 'jenkins' group. This is a problem because it means that 
> I cannot do a docker build from this jenkins file. Some time ago this used 
> to be work but it stopped working for no apparent reason.
>
> Do any of you have any idea what to do about this?
>
> Thanks in advance!
> Chris
>

-- 
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/529a1f58-fb66-4378-9ad5-f5451a2d0624n%40googlegroups.com.


Re: git-plugin 4.7.1 fails

2021-04-29 Thread 'Björn Pedersen' via Jenkins Users
We are running git-4.7.1 without problems. Check that git-client-plugin  
3.7.1 is also installed.

Björn

morten.b...@gmail.com schrieb am Donnerstag, 29. April 2021 um 09:27:39 
UTC+2:

>
> The recommended git tool is: NONE
> 07:00:00 FATAL: org.jenkinsci.plugins.gitclient.GitClient
> 07:00:00 java.lang.NoClassDefFoundError: 
> org.jenkinsci.plugins.gitclient.GitClient
> 07:00:00 at 
> org.jenkinsci.plugins.gitclient.Git$GitAPIMasterToSlaveFileCallable.invoke(Git.java:168)
> 07:00:00 at 
> org.jenkinsci.plugins.gitclient.Git$GitAPIMasterToSlaveFileCallable.invoke(Git.java:149)
> 07:00:00 at hudson.FilePath.act(FilePath.java:1172)
> 07:00:00 at hudson.FilePath.act(FilePath.java:1155)
> 07:00:00 at org.jenkinsci.plugins.gitclient.Git.getClient(Git.java:121)
> 07:00:00 at hudson.plugins.git.GitSCM.createClient(GitSCM.java:906)
> 07:00:00 at hudson.plugins.git.GitSCM.createClient(GitSCM.java:837)
> 07:00:00 at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1290)
> 07:00:00 at hudson.scm.SCM.checkout(SCM.java:505)
> 07:00:00 at 
> hudson.model.AbstractProject.checkout(AbstractProject.java:1215)
>
> reverting to 4.7.0 and it works again.
>
> There is no bug submit here: https://github.com/jenkinsci/git-plugin
>
> jenkins 2.290
>
> --
> MortenB, Oslo, Norway
>
>
>

-- 
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/30b839fe-41e1-4ac5-ab74-ee7f0b7210b5n%40googlegroups.com.


Re: multibranch plugin with gerrit trigger plugin

2021-04-28 Thread 'Björn Pedersen' via Jenkins Users
If you use gerrit-trigger you don't need to discover new branches. You get 
the GERRIT_BRANCH from the trigger data.


A typical checkout looks like:
 checkout ([poll: false, 
scm: [$class: 'GitSCM', 
  branches: [[name: '$GERRIT_BRANCH']],
  doGenerateSubmoduleConfigurations: false,
  extensions: [[$class: 'BuildChooserSetting',
buildChooser: [$class: 
'GerritTriggerBuildChooser']],
],
   gitTool: 'Default',
   submoduleCfg: [],
   userRemoteConfigs: [[credentialsId: '',
refspec: '$GERRIT_REFSPEC',
url: 'ssh:///$GERRIT_PROJECT']]
 ]
])



lar...@gmail.com schrieb am Mittwoch, 28. April 2021 um 13:41:04 UTC+2:

> onsdag 28 april 2021 kl. 11:41:45 UTC+2 skrev ice...@googlemail.com:
>
>> lar...@gmail.com schrieb am Mittwoch, 28. April 2021 um 10:51:59 UTC+2:
>>
>>> Thanks. What I want to achieve in the end is a pipeline with a stage0 
>>> check for uploaded patches, and if that passes have it do a +1 verify vote. 
>>> Then a multistage job that runs of what is submitted.
>>> And I want the pipelines created automatically for master and each 
>>> release branch. I thought I could do this some how with multi-branch and 
>>> some kind of gerrit trigger, either the gerrit-trigger plugin or via gerrit 
>>> webhook plugin..
>>> Regards, Lars
>>>
>>
>> Well, that is possible.  You can combine Jenkinsfile and gerrit trigger 
>> (I  would do that for the stage0 checks), just checkout scm is not possible 
>> at the moment, yuo need to  use the var from gerrit trigger in the checkout 
>> incantation. 
>>
>>
> Ok, even for multi-branch so it can discover new branches? I have not 
> found a method for that to setup gerrit-triggers for new patch-sets. Do you 
> have any hints?
>  
>
>> For the submitted checks multibranch + gerrit-review + (gerrit webhook)  
>> will work. 
>>
>

-- 
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/0dae445d-f035-4c3e-99b3-3955798c9453n%40googlegroups.com.


Re: multibranch plugin with gerrit trigger plugin

2021-04-28 Thread 'Björn Pedersen' via Jenkins Users


lar...@gmail.com schrieb am Mittwoch, 28. April 2021 um 10:51:59 UTC+2:

> Thanks. What I want to achieve in the end is a pipeline with a stage0 
> check for uploaded patches, and if that passes have it do a +1 verify vote. 
> Then a multistage job that runs of what is submitted.
> And I want the pipelines created automatically for master and each release 
> branch. I thought I could do this some how with multi-branch and some kind 
> of gerrit trigger, either the gerrit-trigger plugin or via gerrit webhook 
> plugin..
> Regards, Lars
>

Well, that is possible.  You can combine Jenkinsfile and gerrit trigger (I  
would do that for the stage0 checks), just checkout scm is not possible at 
the moment, yuo need to  use the var from gerrit trigger in the checkout 
incantation. 

For the submitted checks multibranch + gerrit-review + (gerrit webhook)  
will work. 

-- 
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/3ba65f63-974e-42fd-9f4d-5fce4dcbd1d5n%40googlegroups.com.


Re: multibranch plugin with gerrit trigger plugin

2021-04-28 Thread 'Björn Pedersen' via Jenkins Users
There are 2 plugins for gerrit support: 
 - gerrit-trigger  -> does not work with multibranch as  it supplies its 
own way of checking out the right commits, so why would you want to use 
multibranch ( each change in gerrit is on its own branch by gerrit design!)
- gerrit-codereview [1] -> does require multi-branch by design if you use 
it for checkout  (it can also work  together with gerrit-trigger for 
setting voters etc.)


[1] https://plugins.jenkins.io/gerrit-code-review/

Björn
lar...@gmail.com schrieb am Dienstag, 27. April 2021 um 22:21:51 UTC+2:

> Hello, old thread but no answer. I have the same problem. I just can't 
> find out how to set it up to trigger. Anyone have an answer to this. Feels 
> like a very common use-case yet I can not find the documentation for how to 
> set it up.
> Thanks, Lars
>
>
> torsdag 11 februari 2016 kl. 21:39:16 UTC+1 skrev wutin...@gmail.com:
>
>> Hi All,
>>
>> I want to know if multi branch plugin support gerrit trigger?
>>
>> I dont find any options to do this.
>>
>> Or multibranch plugin is just aimed for the commit already been merged 
>> into the git repo?
>>
>> Br,
>> Tim
>>
>

-- 
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/a6310551-10f2-4a05-ad83-8fe591daf999n%40googlegroups.com.


Re: How to fix workspace deletion on slave node

2021-04-16 Thread 'Björn Pedersen' via Jenkins Users
Best idea is to avoid relying on the workspace being preserved at all . So 
if you  are deplyoing something, then  do it by 
installing/copying/whatever  the final artifacts in a place outside the 
workspace.

m.s.sent...@gmail.com schrieb am Freitag, 16. April 2021 um 03:18:23 UTC+2:

> This is a system property that should be set when starting up jenkins. You 
> would want to set *hudson.model.WorkspaceCleanupThread.disabled*  to true 
> to disable deletion of workspaces.
>
> Usage is documented here: 
> https://www.jenkins.io/doc/book/managing/system-properties/
>
> On Thu, Apr 15, 2021 at 11:09 AM DHAVAL JAISWAL  wrote:
>
>> Workspace on Slave node is deleted if the Job is not running/active from 
>> Master Jenkins for some days.
>>
>> How shall I fix this issue?
>>
>> While referring to some forum advising to fix 
>> *hudson.model.WorkspaceCleanupThread.disabled* [ false ]. However, I am 
>> unable to find this parameter.  
>>
>> Guide me on how can I fix this issuer permanently & save my workspace and 
>> build.
>>
>> I see one option in Jenkins is DISCARD OLD BUILD. However, I assume that 
>> check is to retain the build (to see the history) on Master Jenkins. 
>>
>> If needed I can help with some more information.
>>
>> -- 
>> 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/CAH5ShBiSTXMYHuhW%2Bthxj3yMAvAOQWqcxgAUJwSM7ZM4kvGBYA%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/12f2089a-ff4b-4117-8e7f-a6159067e81en%40googlegroups.com.


Re: GitHub Clone to Different Local Directory

2021-03-29 Thread 'Björn Pedersen' via Jenkins Users
Did you try to use credentials in jenkins to store the token  instead of  
fiddling  with token on the machine?
See 
e.g. 
https://stackoverflow.com/questions/61105368/how-to-use-github-personal-access-token-in-jenkins


Then you could do everything in one job instead of  doing some copy-magic 
(which would  horribly break once you start to use more nodes).

Björn
eric@gmail.com schrieb am Samstag, 27. März 2021 um 04:05:44 UTC+1:

> Thanks Mark, I'll check it out.  Has to beat the hokey workaround I worked 
> up.  :)
>
>
>
> Sent from my T-Mobile 4G LTE Device
>
>
>  Original message 
> From: Mark Waite  
> Date: 3/26/21 10:49 PM (GMT-05:00) 
> To: Jenkins Users  
> Subject: Re: GitHub Clone to Different Local Directory 
>
> Good point.  How about the external workspace plugin from GSoC 2016?  
> https://plugins.jenkins.io/external-workspace-manager/
>
> On Fri, Mar 26, 2021 at 8:00 PM eric.fetzer  wrote:
>
>> Thanks for the response Mark..  I'm using freestyle.  Doesn't checkout to 
>> a subdirectory only take relative paths?
>>
>>
>>
>> Sent from my T-Mobile 4G LTE Device
>>
>>
>>  Original message 
>> From: Mark Waite  
>> Date: 3/26/21 6:44 PM (GMT-05:00) 
>> To: Jenkins Users  
>> Subject: Re: GitHub Clone to Different Local Directory 
>>
>> If you're using pipeline, change to that directory with the 
>> dir('/users/username/projectname') { } wrapper around the checkout step;
>>
>> If you're using a freestyle job, use the git plugin extension 'checkout 
>> to a subdirectory' 
>> 
>>
>> On Fri, Mar 26, 2021 at 10:54 AM eric@gmail.com  
>> wrote:
>>
>>> OK, so this is kind of complex so hang with me.  We're moving from 
>>> StarTeam to Github and I'm trying to reproduce what I'm doing in StarTeam 
>>> with Github.  StarTeam was easy because I owned the repository machine as 
>>> well as administrated the tool.  With Github, we're hosted.  So I'm admin 
>>> on the project but can't create an RSA Token on the machine for easy 
>>> access.  So I had to play around to make a personal access token work.  In 
>>> order to make that access token work, I had to run the checkout job on a 
>>> different node so that it was running as a user that lived in Github as 
>>> well (access token's namesake).  So when this job gets called from the 
>>> jenkins job, I want it to clone to the calling job's workspace 
>>> (/opt/jenkins/workspace/).  Well since in order to 
>>> authenticate, it lives in it's own shell, the workspace for this guy, and 
>>> where it wants to clone to, is /home//.  All that 
>>> for my question:  how can I specify what folder to checkout to?  I tried to 
>>> use "checkout to specific local branch" but it fails saying "is not a valid 
>>> branch name".  Well, yeah, branch is referring to branch not folder, lol.  
>>> In StarTeam this is easy, you just specify working folder.  Any help?  
>>> 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-use...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/128374b8-63d5-4b8c-86bb-5f214f5e68d2n%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>> -- 
>> 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/Ob42FqU-0UY/unsubscribe
>> .
>> To unsubscribe from this group and all its topics, send an email to 
>> jenkinsci-use...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtG6VTjt8F7Vj5pJW13VQJTfxCqRuZuDHjj5zZTa3jJ9%3Dg%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-use...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/605e9199.1c69fb81.932c2.d78c%40mx.google.com
>>  
>> 
>> .
>>
> -- 
> 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/Ob42FqU-0UY/unsubscribe.
> To unsubscribe 

Re: hypothesis: Test Results Aggregator - need help

2021-03-17 Thread 'Björn Pedersen' via Jenkins Users
The code[1] definitly does not impose a limit. Does your  mailserver impose 
a limit on the number of recipients in a single mail? Is a mailing list 
involved, e.g mailmain often imposes a limit on the number of 
recipients...? 
Crank up logging and check the logs for reported errors.

Björn


[1] 
https://github.com/jenkinsci/test-results-aggregator-plugin/blob/master/src/main/java/com/jenkins/testresultsaggregator/reporter/MailNotification.java
webde...@gmail.com schrieb am Dienstag, 16. März 2021 um 20:33:01 UTC+1:

> I may have stumbled across the solution to a different conversation that I 
> posted. I noticed that the number of recipients I include in the Recipients 
> list of the Aggregator may be causing me trouble. Would someone be willing 
> to test this hypothesis on their side, too?
>
> I have included 1 email recipient, 11 email recipients, and 12 email 
> recipients in my Test Results Aggregator. With 1 recipient, the job reports 
> as successful and sends out an email; with 11 recipients, the job reports 
> as successful and sends out an email; with 12 recipients, the job reports 
> successful and does not send out an email.
>
> Has anyone encountered a similar situation?
>

-- 
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/5598c5ab-ac6e-4c5b-a893-1c6fb853e55cn%40googlegroups.com.


Re: Using withEnv with withCredentials

2021-03-08 Thread 'Björn Pedersen' via Jenkins Users
Used : 
withEnv([‘http_proxy=https://${PROXY_CREDENTIALS}@proxy-endpoint.com:3128']) 
{ 

Note the single quotes, this needs to be double-quoted for the replacement 
to happen.

Björn



kelvSYC schrieb am Montag, 8. März 2021 um 22:29:00 UTC+1:

> Suppose I have a username and password credential that I use with a 
> withCredentials step, and I wish to use it to construct a URL for use with 
> the http_proxy environment variable. Currently I have this:
>
> withCredentials([usernameColonPassword(credentialsId:’proxy-credentials’, 
> variable: ‘PROXY_CREDENTIALS')]) {
> def url = “https://${env.PROXY_CREDENTIALS}@proxy-endpoint.com:3128”
> withEnv([“http_proxy=${url}”]) {
> // Do something
> }
> }
>
> This gets flagged as unsafe by Jenkins (likely rightly), so I’m wondering 
> what safe way there is to do the same thing.
>
> Something like the following doesn’t work for me:
>
> withCredentials([usernameColonPassword(credentialsId:’proxy-credentials’, 
> variable: ‘PROXY_CREDENTIALS')]) {
> withEnv([‘http_proxy=https://${PROXY_CREDENTIALS}@proxy-endpoint.com:3128']) 
> {
> // Do something
> }
> }
>
> All it does is that the http_proxy variable is populated with the literal 
> ${PROXY_CREDENTIALS} string instead of the value therein.
>
> Any assistance in this would be appreciated.
>
>

-- 
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/2e09f1ff-d7d7-4ba3-a84d-2455dfe1d5acn%40googlegroups.com.


Re: [JCasC] job parameters lost when re-starting docker container / reloading existing configuration

2021-02-22 Thread 'Björn Pedersen' via Jenkins Users
Yes, 

this seems like a general chicken-and-egg problem when specifying 
parameter-config in the Jenkinsfile. It also affects any updated 
Jenkinsfile that adds a new parameter/changes a  parameter , as these 
changes only take effect *after * the job is started. The only really 
working solution would be to run the Jenkinsfile twice (once for setup, 
e.g. parameters) and then to do the real work. But then what to do if the 
Jenkinsfile e.g. depends on a branch parameter? Which jenkinsfile should be 
used?

Björn

r.fuereder schrieb am Freitag, 19. Februar 2021 um 07:57:23 UTC+1:

> Hi Danny et al,
>
>  
>
> I think, I just stumbled over the same problem:
>
>- parameterized pipeline + Jenkins Docker container restart + JCasC + 
>JobDSL (that is re-generating the parameterized scripted pipeline – 
>pipeline from SCM -- during Jenkins startup via 
> “j.j.plugin.JenkinsJobManagement#createOrUpdateConfig: 
>createOrUpdateConfig for ...”)
>   - Problem is (again and again) the first run of pipeline after 
>   Jenkins Docker container restart
>  - Note: I think I am OK with the (missing parameterization) 
>  problem in any very first pipeline run ever, or after changing the 
> pipeline 
>  parameterization
>  - => JCasC or JobDSL might need to address this issue, I 
>  guess/think?
>   - I personally think that these open Jenkins bugs/issues are not 
>   necessarily correctly specified, or let’s say they or their title might 
> be 
>   too generic?
>  - https://issues.jenkins-ci.org/browse/JENKINS-41929 “*Offer 
>  "Build with Parameters" on first build when declarative Jenkinsfile 
> found*
>  ”
> - => No, my problem is also for scripted
>  - https://issues.jenkins.io/browse/JENKINS-43758 “*Parameters 
>  disappear from pipeline job after running the job*”
> - => No, normally parameters stay; it is only gone after 
> Jenkins Docker container restart
> - Actually the comment by Falko Modler in 
> 
> https://issues.jenkins.io/browse/JENKINS-43758?focusedCommentId=380158=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-380158
>  
> describes it perfectly, I think!
>  
>  
>
>  
>
> One possible workaround – that might be OK if there are very few affected 
> parameterized pipelines, or the parameterization is fairly stable, or there 
> are just very few different paramaterizations – seems to be duplicating 
> the parameterization into the JobDSL specification of the pipeline, for 
> example:
>
>  
>
>- In the pipeline code:
>
>  
>
> properties([
>
> parameters([
>
> string(name: 'targetHost', defaultValue: 'my.host.com', 
> description: 'IP/Hostname of target server', trim: true)
>
> ])
>
> ])
>
>  
>
>- In the JobDSL code:
>
>  
>
> pipelineJob(" My pipeline JobName") {
>
>   // Workaround for 
> https://issues.jenkins.io/browse/JENKINS-43758?focusedCommentId=380158=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-380158
>
>   *parameters {*
>
> *stringParam('targetHost', 'my.host.com ', 
> 'IP/Hostname of target server')*
>
> *  }*
>
>   definition {
>
> cpsScm {
>
>   ...
>
>  
>
>  
>
> Are there any updates on this problem?
>
> Or are there open Jenkins (plugin) issues that really address this 
> problem? Or should we file a new one specific for this problem? (If so, I 
> am not even sure for which Jenkins plugin, to be perfectly honest.)
>
> Or is there a better workaround?
>
>  
>
> Thanks,
>
>Reinhold
>
>  
>
>  
>
> *From:* jenkins...@googlegroups.com  *On 
> Behalf Of *Danny Trunk
> *Sent:* Freitag, 16. Oktober 2020 18:43
> *To:* jenkins...@googlegroups.com
> *Subject:* [JCasC] job parameters lost when re-starting docker container 
> / reloading existing configuration
>
>  
>
> Hello everyone,
>
>  
>
> I've set up a container with jenkins.yaml file in $JENKINS_HOME which is 
> loading a parameterized pipeline job:
>
>  
>
> jobs:
>
>   - script: >
>
>   pipelineJob('lineage') {
>
> definition {
>
>   cpsScm {
>
> scriptPath 'Jenkinsfile'
>
> scm {
>
>   git {
>
> configure { git ->
>
>   git / 'extensions' / 
> 'hudson.plugins.git.extensions.impl.SparseCheckoutPaths' / 
> 'sparseCheckoutPaths' {
>
> 
> 'hudson.plugins.git.extensions.impl.SparseCheckoutPath' {
>
>   path('Jenkinsfile')
>
> }
>
>   }
>
> }
>
> extensions {}
>
> remote {
>
>   url '
> https://github.com/dtrunk90/jenkins-lineage-docker.git'
>
> }
>
>   }
>
> }
>
>   }
>
> }
>
>   }
>
>  
>
> In order to retrieve the parameters defined in the 

Re: How to remove CVS plugin ? / Bundeled plugins

2021-02-16 Thread 'Björn Pedersen' via Jenkins Users
CVS has been unbundled as of  2.271 
(https://www.jenkins.io/changelog/#v2.271). So  the next LTS ( based on 
2.777 I guess) should allow you to uninstall CVS. 


Björn

mj1414...@gmail.com schrieb am Montag, 15. Februar 2021 um 18:45:54 UTC+1:

>
> Hello,
>
> the CVS plugin 2.11 has security warnings:
>
>- CSRF vulnerability 
>
>- XXE vulnerability 
>
>
> I don't see an update and it is* "This plugin is up for adoption".*
>
> OTOH, I don't need it - we're using GIT and SVN. So I've tried to remove 
> it - so far in vain.
> "Uninstall" from plugin manager - doesn't seem to do something.
> Shut down Jenkins; removed in .../home/plugins cvs.jpi and the 
> cvs-directory. After restart they are both herr again.
>
> I assume, this is because the plugin is bundled with jenkins.war. (See 
> below)
>
> If this is the case: How do I remove it ?
> If the bundled state is the problem, then should the plugins with security 
> issues and "open for adoption" be unbundeled, so users not needing it, can 
> get rid of it ?
>
> Regards
>
> Martin
>
> Yes, it is bundled in my understanding:
>
> >unzip -l jenkins2_263_3.war | grep pi
> ...
>929025  01-25-2021 15:03   WEB-INF/detached-plugins/cvs.hpi
>
> *...*
>

-- 
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/38074bb8-412c-4637-a39c-c1595962fc6an%40googlegroups.com.


Re: Plugin Build fails with "JellyTestSuiteBuilder"

2021-01-28 Thread 'Björn Pedersen' via Jenkins Users
My first guess would be the  Jenkinsfile ( it seems like a null is passed 
where null is not expected:


buildPlugin(jenkinsVersions: [null, '1.651.2'], failFast: false)

   ^^ 

swate...@gmail.com schrieb am Donnerstag, 28. Januar 2021 um 15:05:04 UTC+1:

> I am trying to release a new version of my plugin but the build keeps 
> failing with the exception
>
> *Caused by: java.lang.IllegalArgumentException: Comparison method violates 
> its general contract! at 
> java.util.ComparableTimSort.mergeLo(ComparableTimSort.java:744) at 
> java.util.ComparableTimSort.mergeAt(ComparableTimSort.java:481) at 
> java.util.ComparableTimSort.mergeCollapse(ComparableTimSort.java:406) at 
> java.util.ComparableTimSort.sort(ComparableTimSort.java:213) at 
> java.util.Arrays.sort(Arrays.java:1312) at 
> java.util.Arrays.sort(Arrays.java:1506) at 
> java.util.ArrayList.sort(ArrayList.java:1462) at 
> java.util.Collections.sort(Collections.java:143) at 
> hudson.ExtensionList.sort(ExtensionList.java:320) at 
> hudson.ExtensionList.ensureLoaded(ExtensionList.java:255) at 
> hudson.ExtensionList.iterator(ExtensionList.java:143) at 
> hudson.diagnosis.NullIdDescriptorMonitor.verify(NullIdDescriptorMonitor.java:68)
>  
> at 
> hudson.diagnosis.NullIdDescriptorMonitor.verifyId(NullIdDescriptorMonitor.java:89)
>   *
>
> I dont have a clue where the exception is comming from or what is wrong in 
> my plugin. I would need some advise how to fix it.
>
> Failing Build: 
>
> https://ci.jenkins.io/job/Plugins/job/maven-artifact-choicelistprovider-plugin/job/master/58/testReport/junit/org.jvnet.hudson.test.junit/FailedTest/windows_8___Build__windows_8org_jvnet_hudson_test_JellyTestSuiteBuilder$JellyTestSuite/
>
> Code:
> https://github.com/jenkinsci/maven-artifact-choicelistprovider-plugin
>

-- 
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/0e708411-5e6f-4ff9-9441-0ab7781f23c3n%40googlegroups.com.


Re: High memory usage by Java process

2020-12-03 Thread 'Björn Pedersen' via Jenkins Users
Check the advanced settings for  the agent at least ssh agents allow custom 
JVM options there.

Björn Pedersen schrieb am Donnerstag, 3. Dezember 2020 um 13:39:46 UTC+1:

> Unless configured otherwise, the agent processes inherit the options from 
> the controller, so this high VM may happen.
>
> Björn
>
> DavidA schrieb am Donnerstag, 3. Dezember 2020 um 13:37:43 UTC+1:
>
>> Hi
>>
>> I have a Centos 7 Jenkins agent. 'top' shows that Jenkins is running a 
>> Java process on it (as expected) but shows 22GB Virtual Memory allocated to 
>> that process. Seems very high, is that reasonable?
>>
>> Best regards
>> David
>>
>

-- 
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/1a99e250-68fd-4d96-867a-a2fdbd845257n%40googlegroups.com.


Re: High memory usage by Java process

2020-12-03 Thread 'Björn Pedersen' via Jenkins Users
Unless configured otherwise, the agent processes inherit the options from 
the controller, so this high VM may happen.

Björn

DavidA schrieb am Donnerstag, 3. Dezember 2020 um 13:37:43 UTC+1:

> Hi
>
> I have a Centos 7 Jenkins agent. 'top' shows that Jenkins is running a 
> Java process on it (as expected) but shows 22GB Virtual Memory allocated to 
> that process. Seems very high, is that reasonable?
>
> Best regards
> David
>

-- 
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/36786ccd-a415-40d8-a94a-cc2369698321n%40googlegroups.com.


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.


Re: Script to get Jenkins CentOS versions?

2020-11-25 Thread 'Björn Pedersen' via Jenkins Users
The problem  probably is that the centos image is not in the first  30 
results . You would need to get the next page(s) until you find a centos 
image.
See https://docs.docker.com/registry/spec/api/#tags for details. And 
remember that this endpoint has a limit on the numbe rof requests in a 
certain timeframe, so be sure to cache the result.
zil...@gmail.com schrieb am Mittwoch, 25. November 2020 um 16:35:57 UTC+1:

> That's what I essentially have already. Just need the correct 
> docker_image_tags_url value, and that post didn't tell me.
>
> On Wednesday, November 25, 2020 at 10:22:41 AM UTC-5 slide wrote:
>
>> This might get you started: 
>> https://gist.github.com/kizbitz/e59f95f7557b4bbb8bf2
>>
>>
>>
>> On Wed, Nov 25, 2020 at 7:58 AM zil...@gmail.com  
>> wrote:
>>
>>> I essentially want to get this list, but in a JSON format in an HTTP 
>>> response. But using this link as my docker_image_tags_url value for my 
>>> script doesn't work of course, that is, it gives a blank list.
>>>
>>>
>>> https://hub.docker.com/r/jenkins/jenkins/tags?page_size=20=1=last_updated
>>> .
>>>
>>> On Wednesday, November 25, 2020 at 9:40:16 AM UTC-5 zil...@gmail.com 
>>> wrote:
>>>
 I want to use the Groovy script in this post 
 
  
 to get Jenkins versions. So I do this, where I change the 
 docker_image_tags_url to point to a Jenkins end point.

 // Import the JsonSlurper class to parse Dockerhub API response
 import groovy.json.JsonSlurper
 // Set the URL we want to read from, it is MySQL from official Library 
 for this example, limited to 20 results only.
 docker_image_tags_url = "
 https://hub.docker.com/v2/repositories/library/jenkins/tags?page_size=30
 "
 try {
 // Set requirements for the HTTP GET request, you can add 
 Content-Type headers and so on...
 def http_client = new URL(docker_image_tags_url).openConnection() 
 as HttpURLConnection
 http_client.setRequestMethod('GET')
 // Run the HTTP request
 http_client.connect()
 // Prepare a variable where we save parsed JSON as a HashMap, it's 
 good for our use case, as we just need the 'name' of each tag.
 def dockerhub_response = [:]
 // Check if we got HTTP 200, otherwise exit
 if (http_client.responseCode == 200) {
 dockerhub_response = new 
 JsonSlurper().parseText(http_client.inputStream.getText('UTF-8'))
 } else {
 println("HTTP response error")
 System.exit(0)
 }
 // Prepare a List to collect the tag names into
 def image_tag_list = []
 // Iterate the HashMap of all Tags and grab only their "names" into 
 our List
 dockerhub_response.results.each { tag_metadata ->
 image_tag_list.add(tag_metadata.name)
 }
 // The returned value MUST be a Groovy type of List or a related 
 type (inherited from List)
 // It is necessary for the Active Choice plugin to display results 
 in a combo-box
 return image_tag_list.sort()
 } catch (Exception e) {
  // handle exceptions like timeout, connection errors, etc.
  println(e)
 }

 However, it just returns Alpine versions. How can I get the CentOS 
 versions?

 Thanks,
 Chris

>>> -- 
>>> 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/365c1f68-145b-499d-a808-bb8b96351386n%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>>
>>
>> -- 
>> Website: http://earl-of-code.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/089d862c-c1eb-4484-943a-9a65eeab45efn%40googlegroups.com.


Re: Job stuck on "git pull --no-edit"

2020-11-17 Thread 'Björn Pedersen' via Jenkins Users
Hi,

this seems like you are mis-using git here. For deploy, checkout into a 
clean workspace and do the build. What happens in your case is, that the 
pull creates a merge commit ( you want fast-forwards only for automated 
updates in most cases), so thats why git  wants a merge commit message. ( 
you could get around by specifiing  a message, but I would advise against 
it.)

Björn

david.v...@gmail.com schrieb am Dienstag, 17. November 2020 um 15:26:14 
UTC+1:

> Hello, 
>
> I have the following simple script. I just want to connect via ssh to my 
> build server, "git pull" and just build the docker and push it to the 
> registry.
>
> (If i don't include the "git pull --no-edit", it works fine)
>
> I just want to do "git pull". But when there are changed being pulled, git 
> gives me a "commit message" editor, and won't let me continue until i enter 
> something.This blocks me from automatically deploying, so i'm trying with 
> "--no-edit" but the deployment gets stuck there for some reason (i i do it 
> manually, works properly)
>
> YML_FILES="eks/"
> YML_PATH="infra-api-server-deployment.yaml"
> DOCKER_PATH="/api-server"
> IMAGE_NAME="api-server"
> cd $DOCKER_PATH
> git pull --no-edit   *< STUCK HERE*
> docker build -t $IMAGE_NAME:$NEW_VER . 
> docker push $IMAGE_NAME:$NEW_VER 
> cd $YML_FILES
> kubectl apply -f $YML_PATH
>
> Help would be greatly appreciated! 
>
> David
>
>
>

-- 
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/b08ac8f5-ee9f-4f23-8a5c-f489db47ab23n%40googlegroups.com.


Re: How do you set java options for ssh agents

2020-09-28 Thread 'Björn Pedersen' via Jenkins Users
I think this is  simply because the agent process survives the master 
restart (that is actually a feature) so if agent settings change, you need 
to disconnect and connect the agent (or otherwise restart the agent process 
to pick up the changes).

timb...@gmail.com schrieb am Freitag, 25. September 2020 um 20:03:25 UTC+2:

> Thanks. I believe you were saying stop/start because you're using Docker 
> container. In your Docker example, stopping and restarting the Docker 
> container is analogous to rebooting (power cycling, or sudo rebooting) the 
> physical or virtual machine hosting the Jenkins service.
>
> In this thread I'm saying that restarting the Jenkins service (which 
> resides within a container or vm that is NOT being restarted/rebooted) IS 
> sufficient to apply MOST CasC settings, however, NOT the ssh agent 
> jvmOptions. It's not a blocking problem, bc I can get the desired effect by 
> rebooting master/controller and agent machines. But it's a mystery I'd like 
> to understand better, bc as I scale this cluster and rll out new 
> configuration changes to it, I'm going to need to understand these 
> mechanics.
>
> Would this be an appropriate thread for jenkins-developers group? Is there 
> another forum you could recommend to ask detailed questions about JCasC? 
> (I'm on the gitter channel but it's quite hit and miss due to the format)
>
> On Friday, September 25, 2020 at 8:56:43 AM UTC-7 kuisat...@gmail.com 
> wrote:
>
>> Restart Jenkins using the CLI(
>> https://www.jenkins.io/doc/book/managing/cli/) it is the same make it 
>> from the UI. When I said stop/start, I mean stop/start the Jankins 
>> daemon/service/Docker container/Whatever. The reason it is because IIRC 
>> JCasC runs on the start time of the Jenkins process, and also IIRC if you 
>> make changes on the JCasC config file and reload the configuration, or 
>> restart from UI the JCasC configuration is not recreated because the stage 
>> where it is run is not running on those restart ways. Probably someone with 
>> the deepest acknowledge of JCasC can add more context. 
>> It is easy to check, run a Jenkins Docker container configured with 
>> JCasC (e.g. 
>> https://github.com/kuisathaverat/jenkins-issues/tree/master/JENKINS-63703) 
>> then connect to the container and modify the JENKINS_HOME/jenkins.yaml file 
>> and restart from UI or CLI, the JCasC changes will not apply if you stop 
>> the Docker container and start it again the changes are applied.
>>
>> El vie., 25 sept. 2020 a las 17:33, Tim Black () 
>> escribió:
>>
>>> Thanks. What's the difference between "restart Jenkins from UI" and 
>>> "stop the Jenkins instance and start it again"? In the latter, how are you 
>>> implying that Jenkins gets stopped and restarted, through the CLI? Just 
>>> trying to understand what you're saying - it sounds like you're implying 
>>> CasC settings aren't applied when you restart jenkins through the GUI, but 
>>> they are when you restart through the CLI..
>>>
>>> I don't think this explanation is relevant to my use case bc I *never* 
>>> restart 
>>> jenkins through the GUI. In the workflow I outlined above, I am running an 
>>> ansible playbook on my jenkins cluster, over and over, and each time if 
>>> there is a config change, it restarts the jenkins service through the CLI 
>>> using a jenkins admin credentials (using an active-directory user 
>>> actually). This appears to *not *have the desired effect of applying 
>>> the new agent jvmOptions upon next connection of the agent, whereas when I 
>>> simply reboot the entire machines (master/controller and agents), the new 
>>> jvmOptions are used in the SSHLauncher). Note that *I do not have this 
>>> same problem with other CasC settings, only ssh agents.*
>>>
>>> On Friday, September 25, 2020 at 3:05:59 AM UTC-7 kuisat...@gmail.com 
>>> wrote:
>>>
 ok, I think I know what happens, I saw it before using Docker and 
 JCasC, if you make changes on the JCasC and restart Jenkins from UI the 
 changes are not applied because JCasC is not executed on that restart, but 
 if you stop the Jenkins instance and start it again the changes are 
 applied 
 IIRC is how it works.

 El miércoles, 23 de septiembre de 2020 a las 23:37:18 UTC+2, Ivan 
 Fernandez Calvo escribió:

> I will configure a test environment with JCasC that has jmvOptions too 
> see how it behaves, then we will know if it is an issue or not, in any 
> case 
> is weird.
>
> El El mié, 23 sept 2020 a las 22:10, Tim Black  
> escribió:
>
>> More info: In my case, a reboot is definitely needed. A 
>> disconnect/reconnect does not suffice, nor does rebooting just the 
>> master/controller or the agent in sequence - *the only way I see the 
>> correct jvmOptions being used is by rebooting the entire cluster at once*
>> . 
>>
>> I'm using Jenkins 2.222.3, ssh build agents plugin 1.31.2. 
>>
>> Another probably important 

Re: Help with JNLP-agent lost connections, Nothing on Google helps.

2020-09-22 Thread 'Björn Pedersen' via Jenkins Users
Current Weekly ( that is what it seems you are using) is 2.257 now. There 
were some changes to remoting, so make sure  the agent.jar on the the 
client machines is up-to-date  as well. 

And how do you connect to the windows clients? Running it as a windows 
service, manually starting it , ssh ???

Björn

tlnar...@gmail.com schrieb am Dienstag, 22. September 2020 um 09:00:07 
UTC+2:

> Eagerly , I'm waiting for the root cause and resolution 
>
> On Thursday, July 4, 2019 at 7:47:00 PM UTC+5:30 ruslan_zasukhin wrote:
>
>> Hi Everbody
>>
>> I am fighting with this about 2 weeks and so far no any success. 
>> I have read dozen answers on internet about similar troubles - nothing 
>> helps.
>>
>> I have upgrade today Java on master and all windows-slave machines to 
>> latest 8_211, not helps.
>> Jenkins also is latest 2.183 and all plugins up to date.
>>
>> *** So, problem is that windows-slave machines SOMETIMES get closed JNLP 
>> connection.*
>> The same machines sometimes are able to execute job with success.
>>
>> ** May be jenkins-gurus can check Exception-stack below and point where 
>> to search?
>>
>> ** This failure happens at any time at any place of a job. 
>> ** MASTER computer is Mac OS X
>> ** We have around few windows computers (mostly VM on virtual Box,) 
>> few Linux machines (also virtual bog) and few Macs - physical macs 
>> are used.
>>
>> ** Linux and Mac works fine.
>> ** For years Windows also was fine, glitches have started about 2 weeks 
>> ago,
>> On that day we was yet on 2.163
>>
>>
>> =
>>
>> FATAL: command execution failed
>> java.nio.channels.ClosedChannelException
>>  at 
>> org.jenkinsci.remoting.protocol.NetworkLayer.onRecvClosed(NetworkLayer.java:154)
>>  at 
>> org.jenkinsci.remoting.protocol.impl.NIONetworkLayer.ready(NIONetworkLayer.java:179)
>>  at org.jenkinsci.remoting.protocol.IOHub$OnReady.run(IOHub.java:795)
>>  at 
>> jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
>>  at 
>> jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59)
>>  at 
>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>>  at 
>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>>  at java.lang.Thread.run(Thread.java:745)
>> Caused: java.io.IOException: Backing channel 'JNLP4-connect connection from 
>> 192.168.2.160/192.168.2.160:1112' is disconnected.
>>  at 
>> hudson.remoting.RemoteInvocationHandler.channelOrFail(RemoteInvocationHandler.java:214)
>>  at 
>> hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:283)
>>  at com.sun.proxy.$Proxy81.isAlive(Unknown Source)
>>  at hudson.Launcher$RemoteLauncher$ProcImpl.isAlive(Launcher.java:1150)
>>  at hudson.Launcher$RemoteLauncher$ProcImpl.join(Launcher.java:1142)
>>  at hudson.tasks.CommandInterpreter.join(CommandInterpreter.java:155)
>>  at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:109)
>>  at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:66)
>>  at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
>>  at 
>> hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741)
>>  at hudson.model.Build$BuildExecution.build(Build.java:206)
>>  at hudson.model.Build$BuildExecution.doRun(Build.java:163)
>>  at 
>> hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:504)
>>  at hudson.model.Run.execute(Run.java:1818)
>>  at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
>>  at hudson.model.ResourceController.execute(ResourceController.java:97)
>>  at hudson.model.Executor.run(Executor.java:429)
>> FATAL: Unable to delete script file 
>> C:\Users\Ruslan\AppData\Local\Temp\jenkins4887328775441465037.bat
>> java.nio.channels.ClosedChannelException
>>  at 
>> org.jenkinsci.remoting.protocol.NetworkLayer.onRecvClosed(NetworkLayer.java:154)
>>  at 
>> org.jenkinsci.remoting.protocol.impl.NIONetworkLayer.ready(NIONetworkLayer.java:179)
>>  at org.jenkinsci.remoting.protocol.IOHub$OnReady.run(IOHub.java:795)
>>  at 
>> jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
>>  at 
>> jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59)
>>  at 
>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>>  at 
>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>>  at java.lang.Thread.run(Thread.java:745)
>> Caused: hudson.remoting.ChannelClosedException: Channel "unknown": Remote 
>> call on JNLP4-connect connection from 192.168.2.160/192.168.2.160:1112 
>> failed. The channel is closing down or has closed down
>>  at hudson.remoting.Channel.call(Channel.java:950)
>>  at 

Re: [Gerrit-Trigger Plugin] Unable to connect successfully to our Gerrit server via the REST API

2020-08-24 Thread 'Björn Pedersen' via Jenkins Users
Hi,

the gerrit-trigger-plugin requires ssh access ( stream-events is only 
available via ssh in a standard setup).  Check the gerrit code review 
plugin (https://plugins.jenkins.io/gerrit-code-review/) if  
you  don't need stream events triggering.


Björn

bbr...@ucdavis.edu schrieb am Sonntag, 23. August 2020 um 06:24:40 UTC+2:

> I'm sorry for trying to revive this, but I didn't receive any answers from 
> my initial posting.
>
> I'm still currently blocked on this and some assistance, if possible, 
> would be greatly appreciated.
>
> Kind regards,
> Bobby
>
> On Friday, August 14, 2020 at 5:55:56 AM UTC-7 Bobby Bruce wrote:
>
>>
>> Dear all,
>>
>> We are currently in the process of setting up a Jenkins server to listen 
>> and respond to events on our Gerrit code review system. As such, we are 
>> using the "Gerrit-Trigger" plugin. A small problem is that those running 
>> our Gerrit server will not give us SSH access. We therefore have to rely 
>> solely on Gerrit's REST API. We have a HTTP username and password setup 
>> which we have verified is correct and has adequate permissions.
>>
>> When adding the Gerrit server to the Gerrit-Trigger server list we add 
>> the frontend URL and, in the advanced section, select "Use REST API"  then 
>> enter our Gerrit HTTP Username and Password. Upon clicking "Test REST 
>> Connect" we receive the "Success" message. I have confirmed that we receive 
>> an error message when entering the wrong username and password, so I assume 
>> the Gerrit-Trigger plugin is able to make some kind of connection. When 
>> saving and leaving the configuration page we try to start the 
>> Gerrit-Trigger server by pressing the red button on the Gerrit-Trigger 
>> dashboard. The button blinks for a few seconds then stops. Looking into the 
>> Jenkins log, the following is given:
>>
>> `2020-08-14 04:26:35.693+ [id=37] INFO c.s.h.p.g.t.
>> GerritProjectListUpdater#tryLoadProjectList: Not connected to 
>> gem5-review, waiting for 64 second(s)`
>>
>> The only theory we have right now is that perhaps the Gerrit-Trigger 
>> plugin requires SSH access as a prerequisite. We can't find this explicitly 
>> noted anywhere, and we don't know why this would be the case given the 
>> plugin has the access it requires via the REST API. If this is the case, 
>> it'd be nice if someone could verify this for us. If not, we would 
>> appreciate some help with this issue.
>>
>> Attached is our gerrit-trigger.xml configuration file (passwords 
>> redacted).
>>
>> Jenkins Version: 2.235.2
>> Gerrit Trigger Version: 2.30.5
>> Gerrit Code Review Version: 3.2.3-1238-g443f7314cb
>>
>> Thank you very much for your time.
>>
>> Kind regards,
>> Bobby
>>
>>
>>

-- 
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/acc0fa90-c587-463b-9de2-cf4f57a8d7f0n%40googlegroups.com.


Re: Multibranch Pipeline job creating multiple Checkout Directories in Workspace

2020-08-20 Thread 'Björn Pedersen' via Jenkins Users
This standard behaviour if jobs run in parallel. The first run uses:
trunk%2FPlatform => the workdir for the job
trunk%2FPlatform@tmp => the checkout for the Jenkinsfile to set up the job.

the @n dirs are created for further parallel runs. 

Björn


>

-- 
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/5219e400-ad91-48c8-ac50-dd9f81767c3bn%40googlegroups.com.


Re: Need help - build "Execute Shell"

2020-07-29 Thread 'Björn Pedersen' via Jenkins Users



>- 
>
>
>Create an SSH key pair (public/private) Ran the command “ssh-keygen -t 
>rsa -C "Jenkins agent key" -f "jenkinsAgent_rsa" “
>- 
>
>Create an SSH credential in the Jenkins machine and put the private 
>key there Created the credentials and put jenkinsAgent_rsa into it.
>
> These steps are fine
 

>
>- 
>
>Create an SSH agent see 
>
> https://github.com/jenkinsci/ssh-slaves-plugin/blob/master/doc/CONFIGURE.md#configure-launch-agents-via-ssh
>  – 
>This is creating a node which I didn’t do before – so I created the node 
>and selected the credential with the private key. The verification 
> strategy 
>slect is non-verifying.
>- 
>   
>   Select the SSH credential created before as credentials
>   - 
>   
>   Chose the verification strategy that you want, see the 
>   documentation, if you have problems start with the "Non verifying 
>   Verification Strategy" you can change it later
>   
>
This doing something completly different, you  are creating a jenkins agent 
via ssh,  what you need is an ssh-agent. 

I assume you are using pipelines, the wrap the ssh-calling sh step in an 
sshagent wrapper (best to use the Snippet generator for the details).
 

>
>- 
>
>Add the public key on ~/.ssh/authorized_keys This was done
>
>
Fine again ( at least if ~ expand to the correct user (whatever jenkins is 
running the agent as), unless you also explicitly specify the user in your 
ssh requests.  From the log it looks like
the agent is running as root (no a good idea, but that is another thing), 
so you would need to add the key to /root/.ssh/authorized_keys (and 
possibly allow remote root logins in the sshd config).

but i am not able to establish the connection between jenkins and ssh server
> my ssh and jenkins server both are hosted on same ip
>

-- 
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/adfbee65-899b-4af6-9fbe-493ae9f50af1n%40googlegroups.com.


Re: Multi-line parameter description in declarative pipeline

2020-06-15 Thread 'Björn Pedersen' via Jenkins Users


Am Montag, 15. Juni 2020 14:45:42 UTC+2 schrieb Al Silver:
>
> If I remove the spaces/tab at the beginning of the line, I'm left with 
> "ugly" code that's not maintaining indentations...  T
>


Not remove from the source, but from the assigment value:

"""
   -...
  -
""..stripIndent()

 

>
> On Friday, June 12, 2020 at 10:20:13 PM UTC-4, slide wrote:
>>
>> The triple quote strings are taken as is, so just remove the tabs/spaces 
>> at the start of the lines.
>>
>> On Fri, Jun 12, 2020, 08:29 Al Silver  wrote:
>>
>>> Hi,
>>>   How can I have a detailed description field that is properly displayed 
>>> when building with parameters.  The example below is obviously not good 
>>> coding practice
>>>
>>> parameters {
>>> // Optional //
>>>
>>> string(name: 'isis_thresh', defaultValue: '',
>>> description: 'Threshold for ISIS Nbr last_state_change 
>>> in format of 4h25s (e.g., 40s, 5m40s, 3h5m40s, 2d, 4w2d). Neighbor uptimes 
>>> that are less than this value will be flagged as an error.')
>>>
>>>
>>> }
>>>
>>> I'd like to do something like this but then the output when building the 
>>> job contains the tabs and looks bad... I'd like each of the lines in the 
>>> output to display against the left hand margin.
>>>
>>> parameters {
>>>
>>> string(name: 'isis_thresh', defaultValue: '',
>>> description: '''Threshold for ISIS Nbr 
>>> last_state_change in
>>> format of 4h25s (e.g., 40s, 5m40s, 
>>> 3h5m40s, 2d, 4w2d).
>>> Neighbor uptimes that are less than this 
>>> value will
>>> be flagged as an error.''')
>>>
>>> }
>>>
>>> Thx
>>> Al
>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "Jenkins Users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to jenkins...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/cf6402d1-6a01-4ed3-a244-445366836ecfo%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>>

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


Re: Unable to install or update plugins in jenkins

2020-05-22 Thread 'Björn Pedersen' via Jenkins Users
Hi,

this looks like a  dependency can not get installled., probably due to 
jenkins not seeing the update center. So you need to manually upload all 
dependencie before your plugin.

Björn

Am Donnerstag, 21. Mai 2020 13:07:19 UTC+2 schrieb Sivakumar Durairaj:
>
> Hi,
>
> I am running jenkins in corporate network, where i am trying to 
> install/update jenkins. (downloading .hpi and then uploading)
>
> But installation  is not happening after succesfull upload and failed with 
> below reason.
>
> Caused: java.io.IOException: Failed to load 
> http://updates.jenkins-ci.org/download/plugins/branch-api/2.0.19/branch-api.hpi
>  to 
> /app/jenkins/taaa-build/plugins/branch-api.jpi.tmp
> at 
> hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:1146)
> Caused: java.io.IOException: Failed to download from 
> http://updates.jenkins-ci.org/download/plugins/branch-api/2.0.19/branch-api.hpi
> at 
> hudson.model.UpdateCenter$UpdateCenterConfiguration.download(UpdateCenter.java:1172)
> at hudson.model.UpdateCenter$DownloadJob._run(UpdateCenter.java:1677)
> at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1874)
> at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1651)
> 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:748)
>

-- 
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/d4aaca30-79c3-40bb-9fa0-3278d5aa0eaa%40googlegroups.com.


Re: python script not executing in "execute python script" step

2020-04-27 Thread 'Björn Pedersen' via Jenkins Users
Hi,

this looks like there is no python in the path on the agent running the 
job. The "Execute python"  step will not magically supply a python 
installation.

Björn

-- 
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/098ffaaf-4df0-4ef4-930d-db61db431395%40googlegroups.com.


Re: Jenkins.war and Jenkins as service

2020-03-24 Thread 'Björn Pedersen' via Jenkins Users


Am Dienstag, 24. März 2020 10:26:23 UTC+1 schrieb raviraj shitole:
>
> Actually its an organization wide setup which is done as a service(Jenkins 
> is installed as a service on Ubuntu)
>
> That's the reason i am trying to connect it that way. Everything is 
> working fine, even the chrome browser is launched in the background. The 
> tests are some how executed but it not visible. Everything happens in the 
> background.
>
>>
>>
That is the whole idea behind using Jenkins,  automated testing without 
human intervention.  To develop and debug a test,  just start it manually 
in your environment.

-- 
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/670b445f-28c5-426a-aec4-dd149f1a90a2%40googlegroups.com.


Re: Jenkins.war and Jenkins as service

2020-03-24 Thread 'Björn Pedersen' via Jenkins Users


Am Dienstag, 24. März 2020 08:13:10 UTC+1 schrieb raviraj shitole:
>
> Hi Mark,
>
> Thank you was able to install the agent as a service, but now when i 
> execute the tests chrome browser is not visible on the desktop. The process 
> starts in the background and exits. 
> How do i make the browser visible now?
>

Don't  run the agent as a service. 
 
 service -> no desktop access, so no windows visible
not service -> desktop access 
 

> Thanks
> Raviraj
>
> On Mon, Mar 23, 2020 at 11:25 PM Mark Waite  > wrote:
>
>> See  https://github.com/kohsuke/winsw/issues/210 for some suggestions to 
>> try
>>
>> On Mon, Mar 23, 2020 at 11:32 AM Raviraj Shitole > > wrote:
>>
>>> I am getting an error "WMI access denied error" while trying to install 
>>> the Slave agent as a service on windows.
>>>
>>> what should we do now?
>>>
>>> On Fri, Mar 20, 2020 at 11:47 PM Mark Waite >> > wrote:
>>>
 Jenkins running as a service on Windows does not have access to the 
 desktop by default.

 Jenkins running from the desktop using `java -jar jenkins.war` from a 
 Windows command prompt will have access to the desktop.

 If you want to run Jenkins as a service and access the desktop, you 
 should probably provide agents which are started from a desktop Windows 
 environment so that they have full access to the desktop.



 On Fri, Mar 20, 2020 at 11:36 AM raviraj shitole >>> > wrote:

> Hi All,
>
>  
>
> I am a difficulty with the way Jenkins is being installed.
>
>  
>
> When we install Jenkins as Server, I am facing difficulty in test 
> automation. The browser doesn’t launch and it gives error that some DevSH 
> tool is missing.
>
>  
>
> Now when I start Jenkins Jenkins.war, there is no problem with the 
> test execution.
>
>  
>
>  
>
> Can someone please let me know the difference between Jenkins as 
> service and Jenkins.war? And also how to solve the error with Jenkins as 
> a 
> service.
>
>  
>
> Awaiting your Response.
>
>  
>
> -Regards,
>
> Raviraj
>
> -- 
> You received this message because you are subscribed to the Google 
> Groups "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send 
> an email to jenkins...@googlegroups.com .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/jenkinsci-users/e120511f-20b9-423f-bc37-d7639f856505%40googlegroups.com
>  
> 
> .
>
 -- 
 You received this message because you are subscribed to the Google 
 Groups "Jenkins Users" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to jenkins...@googlegroups.com .
 To view this discussion on the web visit 
 https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtEvJAjfk9CMvSFFvQ2sVGzbe4uRtdBpacJwa9n4oxAcvg%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 jenkins...@googlegroups.com .
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/jenkinsci-users/CAFYbxtffph-5ZwFeX2Y1E8u7EMcwv9Xrow_6we0zK8ZNj8skdQ%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 jenkins...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtF7MeMWhGETdzVSntTrssSMnKD3QK9oAYKOMW1%2BS3Trgg%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/e8160d9e-f88f-43a7-b57d-9befbb7b5e45%40googlegroups.com.


Re: Git Plugin - How specify use ssh in "Repository URL" ?

2020-01-23 Thread 'Björn Pedersen' via Jenkins Users
HI,

that is a hostkey verifiicaction error. Solution: 
 
a) manually install the hostkey on the build agent
b) configure ssh to skip hostkey verification (the more insecure option)

Björn

Am Dienstag, 21. Januar 2020 18:24:55 UTC+1 schrieb Ed of the Mountain:
>
> *What I Tried:*
>
> 1) Set *Source Code Management > GIT > Repository URL* to:
>
> acme...@vs-ssh.visualstudio.com:v3/acmeinc/my-app/my-app
>
> Failed to connect to repository : Command "git ls-remote -h -- 
> acme...@vs-ssh.visualstudio.com:v3/acmeinc/my-app/my-app HEAD" returned 
> status code 128:
> stdout:
> stderr: Host key verification failed.
> fatal: Could not read from remote repository.
>
> *Work-Around*
>
> My work-around was to change job to use a bash shell.  
>
> However, I very much miss the "*Recent Changes*" section that was 
> displayed in my job previously.  
>
> I *think* the "*Recent Changes*" were generated from the GIT Plugin.
>
>
>
> echo "git clone using public SSH key of build slave..."
> echo "Works but no 'Recent Changes' section for your job"
> git clone acme...@vs-ssh.visualstudio.com:v3/acmeinc/my-app/my-app .
>
> Thanks in advance for any tips or suggestions,
>
> -Ed
>
>
>
>

-- 
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/ce6ffb2d-5c40-479e-9fc8-fffdba4d5e1e%40googlegroups.com.


Re: Perform actual hardware tests using jenkins pipeline and kubernetes

2020-01-19 Thread 'Björn Pedersen' via Jenkins Users
Hi, 

configure each HW-machine as an agent with appropirate labels and the 
request these labels in your job. 
I recommend to use the modern pipeline jobs as there you only need to 
request all the wanted labels in a node().
Otherwise you probably need the multi-job plugin.

Björn

Am Montag, 20. Januar 2020 07:19:00 UTC+1 schrieb touseef:
>
> Can anyone point me in right direction,
>
> I have a use case as follow:
>
> Kubernetes master running the jenkins and i have n number of physical 
> machine connected with different hardwares,So what i want to achieve is 
> when a specific job is triggered in jenkins to execute a test on hardware , 
> k8's(kubernetes master) should route and connect to that machine in a pool 
> which has requiste hardware and execute the tests.
>
> Any pointer how to achieve is appreciated
>

-- 
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/9a78e3e9-884f-41bc-b886-9ddf57c13c76%40googlegroups.com.


Re: Need Help in executing Rest API in Jenkins Job

2020-01-13 Thread 'Björn Pedersen' via Jenkins Users
Hi,

from your GIT Bash mention I assume that you are  running on Windows. 
Are you sure jenkins is using your git bash as shell, and not either 
another bash or powershell?

Or is it even running on a different host, where  may some programms 
(curl/sed) are not available?
Try running just curl to see the output before trying to catch the result.


Björn
Am Dienstag, 14. Januar 2020 05:43:38 UTC+1 schrieb phanindra m:
>
> Hi,
>
> I'm Trying to Run Rest API in Jenkins Job, but facing few issues. 
>
> below command will fetch the session id of an application and stores it in 
> a var variable. this command is working fine in GIT Bash, but when i trying 
> to run this command in Execute Shell option in jenkins it is not working.  
> So can any one help me on this.
>
> var=$(curl --silent 'http://URL/Login?sUserId=UserID=password' 
> | sed -nr 's/.*>(.*)<.*/\1/p')
> echo $var
>
> Thanks In Advance,
>
> Phani
>

-- 
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/ae7358ee-7325-498e-829a-71d15597b1dc%40googlegroups.com.


Re: Push sources checked out from Gerrit to Git on jenkins Job using pipeline

2020-01-13 Thread 'Björn Pedersen' via Jenkins Users
Hi,

Checkout from the source with scm and just add a shell step that does the 
push. Per default the scm implementation also will use the installed 
commandline git client.
If you need credentials for the push, you can wrap the shell step in a 
withCredentials.

But maybe just using the gerrit replication instead could be  a better 
option.

Björn

Am Dienstag, 14. Januar 2020 06:19:48 UTC+1 schrieb Dominic Espiritu:
>
> Hi,
>
> I would just like to ask if possible to push updates from my Gerrit 
> repository to Git repository using SCM in jenkins? I only tried doing this 
> on a manual steps from my terminal window, Any suggestions would be a good 
> help.
>
> Thanks,
> Dominic
>

-- 
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/2e89c015-febc-4381-a923-fcb08013433d%40googlegroups.com.


Re: Changes not being displayed on jenkins build summary and in email body

2020-01-09 Thread 'Björn Pedersen' via Jenkins Users


Am Donnerstag, 9. Januar 2020 15:59:08 UTC+1 schrieb Dominic Espiritu:
>
> On my jenkins Job (type of pipeline), I use gerrit-trigger and on the 
> pipeline script definition I run "git fetch --tags --progress -- 
> ${PROJECT_URL} ${GERRIT_REFSPEC} && git checkout FETCH_HEAD",
>

You need to make jenkins aware that you  are using git, so use a 
scm/checkout  step to checkout the changes. 

 
checkout(
changelog: true, poll: false,
scm: [$class: 'GitSCM',
  branches: [[name: "$GERRIT_BRANCH"]],
  doGenerateSubmoduleConfigurations: false, submoduleCfg: [],
  userRemoteConfigs: [
  [refspec: GERRIT_REFSPEC,
   url:  + GERRIT_PROJECT
  ]
  ],
  extensions: [
  [$class: 
'hudson.plugins.git.extensions.impl.BuildChooserSetting',
   buildChooser: [$class: 
"com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.GerritTriggerBuildChooser"
]],
  ]
]
)



-- 
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/c7c012b4-da19-4f9b-8fd8-171a6752ecad%40googlegroups.com.


Re: why does multibranch pipeline fetch branch source 3 times?

2019-12-18 Thread 'Björn Pedersen' via Jenkins Users


Am Dienstag, 17. Dezember 2019 17:23:15 UTC+1 schrieb Tim Black:
>
> Understood. Note that, even with "CleanBeforeCheckout" I have to "re fetch 
> tags" because my initial checkout, the one that "Discover Tags" causes, is 
> cleaned up afterwards. This is very counter-intuitive, because there's no 
> high level description of what's going on, or why, or what all the words 
> ("Fetch", Checkout"..) mean.
>
> I have empirically determined that "CleanBeforeCHeckout" really means 
> "Clean after the initial checkout/fetch/clone, the one whose sole purpose 
> in life is to scan for Jenkinsfile changes, but before the subsequent 
> second (and maybe third) checkout/fetch/clone operation".
>
> It appears that the former, initial checkout/fetch/clone has controls in 
> BranchSource behaviors to get tags, or do not get tags, etc.. but the 
> subsequent checkout/fetch/clone operations are still a complete mystery to 
> me. Do I have control over when and how those are going to occur? E.g. how 
> can I make the subsequent checkout/fetch/clone operations use `--tags` 
> instead of `--no-tags`?
>

Yes, that behaviour is a feature of all scm-driven pipelines:


   1.  First fetch Jenkinsfile  on master(!) soley to determine what 
   actually to do
   2.  Create a workspace (depending on what is defined in the file, this 
   may be on a completly different host or a throw-away workspace.
   3. Fetch your repo into this workspace ( scm checkout )

You can try to configure the first checkout to use a sparse checkout. 

For Multibranch pipelines, an additional  fetch is done before all this to 
see which  branches have changes that need a build. 

Björn

-- 
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/01389598-8a0b-450a-afe1-ae63ff5f7ebe%40googlegroups.com.


Re: editing jenkins jobs in shell / vi / ssh

2019-12-12 Thread 'Björn Pedersen' via Jenkins Users
Hi,

this looks really unusal and has nothing to do with editing in itself. It 
looks like your http request is never sending data to the server , so most 
probably something is misconfigured (proxy?)  or you are  on an extremly 
slow network (less than 1byte/5 seconds?) .

Björn

Am Donnerstag, 12. Dezember 2019 10:50:18 UTC+1 schrieb Adrianm758:
>
> Is there any way Jenkins jobs can be edited / configured directly in a 
> shell using vi or similar. I'm so sick of getting the "java.lang.Throwable: 
> HttpInput idle timeout" error when using the GUI, especially when it's just 
> a small one-line 
>

-- 
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/98786540-61ee-4baf-a527-f3f67985a702%40googlegroups.com.


Re: How to identify the compatibility plugins?

2019-12-04 Thread 'Björn Pedersen' via Jenkins Users
You should check 
https://jenkins.io/blog/2019/05/30/becoming-contributor-newbie-tickets/ and 
https://github.com/jenkinsci/jenkins/pull/3985:

return isCompatibleWithInstalledVersion() && !isForNewerHudson() && 
!isForNewerJava() 
&& 
isNeededDependenciesCompatibleWithInstalledVersion(cache) && 
!isNeededDependenciesForNewerJenkins(cache) && !
isNeededDependenciesForNewerJava(); 

is the main code used.


Am Dienstag, 3. Dezember 2019 12:16:10 UTC+1 schrieb YanJun Shi:
>
> But I see the function name is ` checkPluginsWithoutWarnings  ` for 
> compatible. 
>
> On Tue, Dec 3, 2019 at 3:05 PM 'Björn Pedersen' via Jenkins Users <
> jenkins...@googlegroups.com > wrote:
>
>> Hi,
>>
>> Am Dienstag, 3. Dezember 2019 08:00:10 UTC+1 schrieb YanJun Shi:
>>>
>>> Hi, everybody
>>> 
>>>   When I use Jenkins, I find that the effect of selecting 'all' and 
>>> 'compatibility' in 'plugins manager' is the same, I want to know how to 
>>> distinguish between compatible plugins. HI
>>>
>>
>> In most cases this expected. Only for very ancient, unmaintained plugins  
>> or if using a rather old jenkins you may find a incompatibility. 
>> Case 1: plugin depends on an now removed other plugin 
>> Case 2: the plugin requires a newer jenkins core than you are using
>>
>> So if you keep everythign up-to-date, almost any current plugin should be 
>> compatible.
>>
>> Björn
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Jenkins Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to jenkins...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/jenkinsci-users/61b3457a-8dc0-4f1f-9fb0-fa050b923d40%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/jenkinsci-users/61b3457a-8dc0-4f1f-9fb0-fa050b923d40%40googlegroups.com?utm_medium=email_source=footer>
>> .
>>
>
>
> -- 
> Shi Yanjun(yJunS)
> Blog:https://github.com/yJunS
>

-- 
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/4b2ef536-5a57-464c-9024-b49000936e3e%40googlegroups.com.


Re: What compression algorithm is used by the pipeline zip step, and is it tunable?

2019-12-02 Thread 'Björn Pedersen' via Jenkins Users
Hi,

I would probably try to compress on the agent before even trying to 
transfer the large data to the master. This avoids load on the master a) 
due to transfer and b) due to compression.
And if the artifacts get really huge, consider storing them  independent 
from jenkins (S3, maven-style repo, whatever matches your use-case).


Björn

Am Montag, 2. Dezember 2019 20:56:02 UTC+1 schrieb Tim Black:
>
> Our projects produce large artifacts that now need to be compressed, and 
> I'm considering my alternatives. The zip step 
> 
>  
> would be a nice non-plugin solution but I'm curious what compression 
> technique this uses. The documentation page linked above doesn't show any 
> options that pertain to compression tuning.
>
> I've also seen the Compress Artifacts Plugin 
> , but I can't 
> tell from its docs either whether the algo is tunable. Also I'd rather not 
> depend on another plugin.
>
> If neither of the above work, I'll simply use sh step to call xz, gzip, 
> bzip, or the like, from my linux-based master.
>
> Thanks for your consideration,
> Tim Black
>

-- 
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/5c3e8877-991d-48af-acde-268c0248fb14%40googlegroups.com.


Re: How to identify the compatibility plugins?

2019-12-02 Thread 'Björn Pedersen' via Jenkins Users
Hi,

Am Dienstag, 3. Dezember 2019 08:00:10 UTC+1 schrieb YanJun Shi:
>
> Hi, everybody
> 
>   When I use Jenkins, I find that the effect of selecting 'all' and 
> 'compatibility' in 'plugins manager' is the same, I want to know how to 
> distinguish between compatible plugins. HI
>

In most cases this expected. Only for very ancient, unmaintained plugins  
or if using a rather old jenkins you may find a incompatibility. 
Case 1: plugin depends on an now removed other plugin 
Case 2: the plugin requires a newer jenkins core than you are using

So if you keep everythign up-to-date, almost any current plugin should be 
compatible.

Björn

-- 
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/61b3457a-8dc0-4f1f-9fb0-fa050b923d40%40googlegroups.com.


Re: How to force jenkins to use $JAVA_HOME/ instead of $JAVA_HOME/jre?

2019-11-14 Thread 'Björn Pedersen' via Jenkins Users
Hi,

Maybe this be a stripped down/incomplete jdk install. If looking into one 
of my jdk installs(manual install with oracle installer), there is a jre 
subdirectory  present. 

Björn

-- 
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/ca918127-f740-4463-b130-55686f6205e3%40googlegroups.com.


Re: problems changing triggers{} in multibranch pipeline Jenkinsfile

2019-10-04 Thread 'Björn Pedersen' via Jenkins Users
Hi,

Am Freitag, 4. Oktober 2019 02:03:17 UTC+2 schrieb Tim Black:
>
> We have a multibranch pipeline job set up to scan a git repo (which 
> contains Jenkinsfile at its root) for branches and create branch-specific 
> jobs for each branch discovered. The Jenkinsfile on a branch specifies:
>
> triggers {
> cron('@midnight')
> }
>
> and this indeed runs nightly at midnight. However, when I delete the above 
> block and commit the Jenkinsfile to my branch, it appears to have no 
> effect. Last night the build still ran at midnight. This is my problem.
>
> I confirmed the change by looking on the branch job configuration page and 
> indeed see an empty BuildTriggers section. There are no triggers specified 
> and none of the trigger checkboxes are checked.
>
> Please confirm whether this is indeed the way I am supposed to disable a 
> trigger specified in a multibranch pipeline Jenkinsfile. 
>
>

The update to the job config for changes made in the jenkinsfile only 
happen once  the jobs runs (before that point, the jenkinsfile is neither 
fetched nor evaluated). So if you changed the trigger today, then it would 
run once tonight and should stop starting after that.  To get the effect 
more immedeatly, you could trigger the job manually.

Björn

-- 
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/4cffef7d-70ec-4f79-8714-780725d90059%40googlegroups.com.


Re: Programmatically searching the artifacts from multiple jobs

2019-08-11 Thread 'Björn Pedersen' via Jenkins Users
Hi, 

I think the best solution would be to use warnings-ng  and set up  suitable 
custom parser (I assume that none of the many available parsers fit your 
use-case). Possibly in combination with the Build Failure Analyzer plugin 
your jobs will show the correct status and where the errors happed.

Björn

-- 
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/ccdab323-3894-4635-a06f-5f7a74c3b3ec%40googlegroups.com.


Re: Pipeline: Shell step oddity removes escaped slash

2019-06-12 Thread 'Björn Pedersen' via Jenkins Users


Am Dienstag, 11. Juni 2019 13:14:28 UTC+2 schrieb Sverre Moe:
>
> I have the following Pipeline step to find specific files:
> sh("find . -regex '.*${packageName}-[0-9.]+-.\\.noarch\\.rpm'")
>
>
You' ll need to escape the backslashes twice: once for groovy and  once for 
the shell
sh("find . -regex '.*${packageName}-[0-9.]+-..noarch.rpm'")

Björn

-- 
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/6f206099-d137-488b-a67d-abf2c003d488%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Two builds for PRs

2019-04-02 Thread 'Björn Pedersen' via Jenkins Users
Hi,

a wild guess: Is this a timing problem? So the push to branch gets build 
before the pull request is filed? 

   push to (new) branch
--->   build 1 triggered
 --> file PR
   ---> build 2 triggers 




???

Am Dienstag, 2. April 2019 04:21:29 UTC+2 schrieb Mark Waite:
>
> Unfortunately, I can't duplicate the problem.
>
> I created a Multibranch Pipeline using 
> https://bitbucket.org/markewaite/jenkins-bugs/src/master/ as the 
> Bitbucket repository and using Bitbucket branch source cloning the 
> repository over https.  The repository is not a fork and has two pull 
> requests.  When I configure the Multibranch Pipeline job to 'Exclude 
> branches that are also filed as PRs', it correctly excludes the two 
> branches that are also filed as pull requests.  When I switch it to include 
> only branches that are filed as PRs, it also behaves as expected.
>
> Sorry, I don't have other ideas to offer.  If you'd like to perform a 
> detailed comparison between your configuration and mine, I'd be willing to 
> temporarily grant you access to my Jenkins server.  Send me a private 
> e-mail if you'd like that access.
>
> Mark Waite
>
>  On Mon, Apr 1, 2019 at 2:56 PM Tom Duerr wrote:
>
>> Hi,
>>
>> Ive updated core Jenkins to 2.150.3 and updated quite a few of the 
>> pipeline plugins.
>> Here is the current list:
>> https://pastebin.com/Maf6iuvQ
>>
>> We're still getting two PRs for each PR created from the origin and not a 
>> fork.
>>
>> I was going to try Slide's advice about filtering on branches but now 
>> that config option
>> indicates that its been deprecated. Not sure where to configure the 
>> "Named Branch" plugin.
>> https://imgur.com/a/smnC98S
>>
>>
>> Other thoughts?
>>
>> Thanks,
>> Tom
>>
>>
>> On Friday, March 29, 2019 at 10:55:04 AM UTC-7, Tom Duerr wrote:
>>>
>>> I will update the pipleline related plugins this weekend and maybe 
>>> upgrade Jenkins (currently at 2.138 ).  
>>> I will report back with results.
>>>
>>> Thanks for the help.
>>>
>>> On Thu, Mar 28, 2019 at 5:29 PM Mark Waite wrote:
>>>


 On Thu, Mar 28, 2019 at 6:22 PM Tom Duerr wrote:

> Mark,
> The issue only happens when the PR is NOT against a fork.  Its been 
> difficult to debug since most of our developers
> use their own forks. 
>

 I think that is the same condition I'm using with the git client plugin 
 multibranch configuration that I'm using.
  

> I think I'm behind on most of the Pipeline related plugins except for 
> the branch-source plugin. I had attempted a big
> upgrade of plugins last week that ended badly. Going to retry this 
> weekend. 
>
> What is the "Jenkins multibranch folder" ? I don't think we're 
> actively using the multibranch plugin. Its unclear to me if we need
> that plugin or not if we're already using the branch-source plugin. 
> The branch-source plugin seems to do everything we need
> to do. I think we will eventually want to use the multibranch plugin 
> to provide different behaviors between a dev, qa or master branch.
> Assuming I actually understand how that plugin works.
>
>
 I should have been more clear.  If you're using the GitHub branch 
 source plugin to define the job, then you're creating a multibranch job.  
 The multibranch job is represented as a folder which contains one job for 
 each branch in the repository.  The containing folder is what I called the 
 "Jenkins multibranch folder".  No other plugin is needed.
  
 Mark Waite

 Tom
>
>
>
> On Thu, Mar 28, 2019 at 5:11 PM Mark Waite wrote:
>
>> That's quite surprising, since my PR evaluation for the git client 
>> plugin on my own fork is running with GitHub and is only showing the 
>> 'pr-merge' job.
>>
>> Is the second job visible when executing in the Jenkins multibranch 
>> folder?  If so, then I'm puzzled, because you're seeing something that 
>> I'm 
>> not seeing.
>>
>> Are you running the most recent versions of the various plugins?
>>
>> Mark Waite
>>
>> On Thu, Mar 28, 2019 at 6:06 PM Tom Duerr wrote:
>>
>>> Mark, 
>>> I already have the "Exclude branches that are also filed as PRs" 
>>> set. 
>>> Guess that's part of my confusion.
>>>
>>> On Thu, Mar 28, 2019 at 4:58 PM Mark Waite wrote:
>>>
 It might also work to filter branches based on the branch name at 
 some level, but that's more complicated that changing the "Discover 
 branches" setting in the plugin.

 Picture looks like this:

 [image: image.png]

 On Thu, Mar 28, 2019 at 5:22 PM Slide wrote:

> This would generally be the branch filter parameter wouldn't it? 
> You'd want to filter on the pr-* and master braches
>
> On 

Re: Node getting CancellationException during startup

2019-02-21 Thread 'Björn Pedersen' via Jenkins Users

We have setups with more than one agent on one host, but they do not share 
the root. Both agents hold a lock on /remoting/remoting.log.0.lck 

So you would probably need to ensure each remoting instance uses a 
different root dir (do not share it wiht other nodes).

Björn

-- 
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/c70944ac-667b-415d-bf8d-4fc37a114f28%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to include pipeline errors in email (Email-ext plugin)

2019-02-04 Thread 'Björn Pedersen' via Jenkins Users
Hi,

you should be ablre to achieve this with the help of the Build Failure 
Analyzer plugin or the warnings-ng plugin (possibly with a custom groovy 
parser )

Björn


Am Montag, 4. Februar 2019 11:39:18 UTC+1 schrieb Faad Sayaou:
>
> I am trying to have the reason as it is printed on the console of my 
> Jenkins instance why a build failed through email. I did the following
>
> try {
> .
>
> } catch (err) {
> cause=err
> emailext body:"Error: $cause ",
> to: 'mye...@gmail.com '
>
> }
>
> The result on the console is something like "dotnetge command not found" 
> and i will like to have this same type of error through email. This is what 
> i get through email
>
> Error: hudson.AbortException: script returned exit code 127
>

-- 
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/07ccd19b-ee12-476a-a19b-1d13fce40eba%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Pass the data thru variable using curl command

2019-01-23 Thread 'Björn Pedersen' via Jenkins Users


Am Dienstag, 22. Januar 2019 05:18:28 UTC+1 schrieb Panneer:
>
> Hi David,
>
> My request is here below:-
>
> def status = "curl -s --max-time 30 POST 'https:url'" -H "Content-type: 
> application/json" -d {"DeAppRulesList": 
> [{"Applion":"02.01.02","Applime":"REFW"},{"Applion":"01.01.01","Applime":"ATP_Branch"},{"Applion":"01.06.07","Applime":"Temp_FW"}]}
>

Carefully check all the quotes! They seem to be incorrect. 
Dump the content of status both with
 echo status

and 
 sh "echo $status" 

to check that all inner quotes survive as you want them to. 

 

> No error and no response received.
>
> Regards
> Panneer
>
>
> On Monday, January 21, 2019 at 9:50:19 AM UTC-7, David Karr wrote:
>>
>>
>> On Sun, Jan 20, 2019 at 8:55 PM panneerrselvam natarajan <
>> pann...@gmail.com> wrote:
>>
>>> Hi All,
>>>
>>> I am using Jenkins for API Testing in Pega Environment.  I can send and 
>>> receive response thru PostMan and SOAPUI and working fine.
>>>
>>> But I want to automate using Jenkins Pipeline.
>>>
>>> Please do let me know, How do i send the data/variable thru CURL command 
>>> in pipeline. I sent the data but not displayed any error message and not 
>>> getting any response also
>>>
>>> I am sending the data which include special charector along with Data. 
>>> Please do let me know the format.
>>>
>>
>> I suggest you show us exactly what you're doing, what the result is, and 
>> what you expected. Exactly.
>>
>>
>>> Regards
>>> Panner
>>>
>>> -- 
>>> 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/ad16f4d1-c745-442a-90df-b2b73b73e03f%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/f33f5103-f0f1-4ea8-b57a-111ebd54c461%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


JEP-210 : Status of pipeline-job plugin

2018-11-28 Thread 'Björn Pedersen' via Jenkins Users
Hi,

The pipeline job-plugin (2.29) still  warns about possible stability 
problems. I do not see much activity in github nor in jira, so what is the 
status here? 
Are there still changes iawating release or is it considerd stable by now?

Björn

-- 
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/8f723c25-3279-445e-9597-1a4785e9320f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins - Add a dynamic label to a build

2018-11-28 Thread 'Björn Pedersen' via Jenkins Users
Hi,

you probably should take a look at the Badge Plugin 
 (together with 
Groovy Post Build plugin probably) for adding the labels. Org use the build 
Name Setter plugin to modify the build name if that matches your build 
better.

Björn
Am Mittwoch, 28. November 2018 16:30:40 UTC+1 schrieb Veena Thomas:
>
> I am trying to achieve the following task in Jenkins: 1) Build a maven 
> project 2) When running the test cases I print certain messages to the 
> console output 3) Parse the console output of the build and determine if 
> certain patterns exist in the output 4) If the pattern exists I want to 
> label the build with a specific string
>
> I have achieved steps 1-3. I am not able to create a dynamic label and tie 
> it to a build. I have a Groovy script that parses the console output and 
> determines if the pattern exists in the build's output.
>
>
> Bamboo provides this feature to label a build based on regular expressions 
> present in the build's console output. Link - 
> https://confluence.atlassian.com/bamboo0606/using-bamboo/jobs-and-tasks/configuring-jobs/configuring-miscellaneous-settings-for-a-job/configuring-automatic-labeling-of-job-build-results
>
>
> I have gone through various existing Jenkins plugins but have not been 
> successful in achieving this functionality. Is there a plugin to achieve 
> this functionality or can I add additional lines in the Groovy script to 
> create a dynamic build label. Any help is appreciated.
>

-- 
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/8c5a0fb2-2f4e-4417-8e07-1783bccbbe39%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Jenkins Docker Sidecar with Container Running a daemon command

2018-11-21 Thread 'Björn Pedersen' via Jenkins Users


Am Dienstag, 20. November 2018 15:33:26 UTC+1 schrieb Justin Seiser:
>
> I want to run ZAP as a proxy in my pipeline, and run my selenium tests 
> through the proxy. Im just using curl in a container in place of selenium 
> for my testing and was able to make this work locally using docker.
>
> In my pipeline, zap starts up, but the pipeline just sits in the zap 
> container after that, never progressing to the second container. I 
> understand why, Ive launched a process as a daemon, its never going to 
> finish, so the step never finished. I just dont understand how to 
> accomplish what I need in jenkins.
>
> stage('Run Zap Proxy'){
> docker.image('owasp/zap2docker-weekly').withRun('-p 8090:8090') { 
> c ->
>   
>
 withRun starts the container.  So you want to add your zap.sh call 
as command here. 

>   docker.image('owasp/zap2docker-weekly').inside("-v 
> $WORKSPACE:/zap/wrk:rw") {
> /* Wait until mysql service is up */
>

   here you start a second container, that  never stops...
 

> sh """
>zap.sh -daemon -port 8090 -host 0.0.0.0 -newsession 
> testing -config api.addrs.addr.name=.* -config api.addrs.addr.regex=true 
> -config api.disablekey=true
>"""
> }
>

   So you never arrive here.
 

> docker.image('cfmanteiga/alpine-bash-curl-jq').inside("--link 
> ${c.id}:proxy") {
> sh 'curl -k -x http://proxy:8090 https://my.fqdn.net'
> sh """
>curl -k -x http://proxy:8090 \
>-X POST https://my.fqdn.net/api/rest/sessions \
>-H 'Content-Type: application/json' \
>-H 'Accept: application/json' \
>-d '{"username":"username","password":"password"}'
>"""
> sh 'sleep 2m'
> sh 'curl -o report.html 
> http://zap/UI/core/other/htmlreport'
> stash includes: 'report.html', name: 'report'
> }
> }
> }
>
> I essentially need to start zap with the command im using in the 'inside', 
> and only kill the container when the second containers steps are complete.
>

-- 
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/e5be8c17-f18c-4d16-bb60-bf4cd6d6d32d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Issue with spaces in string parameter

2018-11-13 Thread 'Björn Pedersen' via Jenkins Users


Am Dienstag, 13. November 2018 00:23:02 UTC+1 schrieb Martin d'Anjou:
>
> I doubt that would fix it, I was curious and try it. Jenkins trims, but it 
> does not split the value on spaces.
>
> The problem might be on how you pass the value to your python script. Can 
> you share that?
>
>
Just to show some problematic ways: 

somescript $parms  
 -> here the shell (not jenkins or python) will split the arguments on 
spaces so you need to quote them
somescript "$params"
 -> now it is a single string, possibly with spaces

or use :

 os.environ.get['params'] inside your script to get the full string.

Björn

-- 
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/1c510222-af7f-4955-a4ff-2b5fdc126f19%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Not able to access and create files in path location(\\\\192.168.0.1/f$/D:\\p.txt)

2018-09-26 Thread 'Björn Pedersen' via Jenkins Users
Hi, 

There are a few  things which could be the reason ( and your descriptions 
are a bit too sparse to guess what is).

1) Is jenkins running on your local host?  (only then the 192 probably 
resolve to a correct host)
if not: 
  2) is the job  running on master  or on an agent ( again, the 192... will 
probably be wrong) 
  3)  does the jenkins host or agent mount the volume in question?

4) as  mentioned: Does the jenkins user (this is not the user logging in ot 
jenkins, but the user that starts jenkins (or the user the agent is running 
as)) have access to the folder?

Generally accessing global ressources like a shared folder from jenkins 
should be done with care, as in a typical setup often more than one job may 
run in parallel.

Björn

Am Mittwoch, 26. September 2018 08:21:19 UTC+2 schrieb Saikumar Korada:
>
> thats fine. Its creating the file in local.
> For ex:shared path(192.168.0.1\\foldername\\p.txt) while executing the 
> program through eclipse its working and creating the filse in shared path. 
> if iam running through jenkins its not creating.
> we are using active directory Authenticator. Not the Jenkins user.
>
> On Monday, September 24, 2018 at 3:42:07 PM UTC+5:30, Andreas Magnusson 
> wrote:
>>
>> Your UNC path looks very strange. As I interpret it you have the 
>> following parts:
>> 192.168.0.1 - localhost probably
>> f$ - automatic share created by windows on drive F:
>> D:\\p.txt - file on another drive
>>
>> Question is, what are you trying to access? You could try:
>> 192.168.0.1\D$\p.txt
>>
>> On Sunday, September 23, 2018 at 3:23:17 PM UTC+2, Saikumar Korada wrote:
>>>
>>> while executing the program through eclipse its working. if iam running 
>>> through jenkins its not working.
>>>
>>

-- 
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/92d2966d-a648-4c11-8221-04aacf6d35ae%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Relationship between GitHub credentials and Jenkins Service account (running as Windows Service)

2018-09-13 Thread 'Björn Pedersen' via Jenkins Users
Hi,

Am Donnerstag, 13. September 2018 17:07:28 UTC+2 schrieb Christopher List:
>
> We are running Jenkins as a windows service on win2012 machine, and it's 
> working fine. 
>
> The problem we have is that we're trying to change the service account 
> that it is running under. 
> The old and new service accounts are both local admins on the machine.
>
> When we change the service account, everything seems to run fine, but our 
> connection to GitHub using a Personal Access token stored in the global 
> jenkins credentials stops working with the classic error:
>
> stderr: Host key verification failed.
> fatal: Could not read from remote repository.
>
>
This is a typical ssh error if the hostkey (from the github server) is 
unknow to the local user account trying to access it. Probably the easiest 
way is to access github via ssh once from that account and accept the 
hostkey.

Björn

-- 
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/81ef25de-a262-4732-933a-da540559905d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to list pipeline tools from Global Tool Configuration?

2018-09-07 Thread 'Björn Pedersen' via Jenkins Users
Hi, 

did you try the snippet generator (or the declarative directive generator)? 
They both list available tools and generate the correct syntax.

Björn

Am Freitag, 7. September 2018 11:06:05 UTC+2 schrieb Mr. Laubrino:
>
> Yes, but what I found is that you would need Overall/Administer permission 
> to see that. Is it common that a user who can create a pipeline job is also 
> an administrator? Isn't it a drawback of Jenkins system? 
>
> Dne čtvrtek 6. září 2018 19:29:07 UTC+2 Cuong Tran napsal(a):
>>
>> Yes, you must be able to access that area to see a list.
>>
>> On Thursday, September 6, 2018 at 5:11:51 AM UTC-7, Mr. Laubrino wrote:
>>>
>>> While going through this pipeline documentation section 
>>> https://jenkins.io/doc/book/pipeline/syntax/#tools - how can one know 
>>> possible pre-configured tools if he is not a Jenkins admin? (I suppose only 
>>> Jenkins admin can manage *Global Tool Configuration)*
>>>
>>

-- 
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/3489d93a-5d19-4649-8a63-8a9ba6290f23%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Problems with ENV variables in jenkins 2.1.41?

2018-09-07 Thread 'Björn Pedersen' via Jenkins Users


> And what global config are you  referring to? 
> Manage jenkins -> global properties -> Environment variables ? 
>
==> works ok on 2.141 here
   

> Node config -> Node properties -> Environment variables?
>

==> A global vars are not overriden  by node vars
==> If defined just as node variable works OK
 

> Job variables (EnvInject plugin??) 
>
> Björn 
>
>

-- 
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/b59fa367-6010-4b43-acaa-c2bfc337b11c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Problems with ENV variables in jenkins 2.1.41?

2018-09-07 Thread 'Björn Pedersen' via Jenkins Users
Hi, 

Am Mittwoch, 5. September 2018 12:46:50 UTC+2 schrieb Gorgonz ola:
>
> Again, I'm new to jenkins. So maybe someone should validate, that it is 
> the jenkins version and not a different presumption ;-)
>
> Using jenkins 2.1.40 with opensuse leap 15.0:
>

What are the jenkins versions (as  reportes e.g. in UI), not the package 
version? 
There is no 2.1.40 ( either you are usin g a LTS version, then it be a 
triple-dotted number, the first in the 2-series is 2.7.1, or a weekly  
build, then it is a doublet, current 2.141) 
I guess you  have a 2.140/141 installed,
And of course the installed plugins also are important. Are they up to date?
And what global config are you  referring to? 
Manage jenkins -> global properties -> Environment variables ?
Node config -> Node properties -> Environment variables?
Job variables (EnvInject plugin??) 

Björn 

-- 
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/f7eed9c5-5f84-4347-933e-bc770e2a29f1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: ConfigFiles 3.0 appears to be mangling config.xml

2018-09-04 Thread 'Björn Pedersen' via Jenkins Users
Just for reference:A jira issue exists: 
https://issues.jenkins-ci.org/browse/JENKINS-53399

Am Dienstag, 4. September 2018 14:29:34 UTC+2 schrieb Benjamin Brummer:
>
> I also had to reconfigure one jenkins job, after this update. 
> Configuration was gone almost completely. All provided maven settings.xml 
> files where gone and but i could set them up again with identical id's.
>
> Am Montag, 3. September 2018 20:14:28 UTC+2 schrieb Michael Weigle:
>>
>> Upgraded from 2.18 to 3.0
>>
>> After the upgrade, configs persist on the filesystem inside config.xml 
>> until that job is visited in the UI (presumably, config.xml is revalidated 
>> at that point and 3.0 throws the error). The attached unreadable_data 
>> message also appears in the Manage Old Data section.
>>
>> Old config.xml shows this comparator: > class="org.jenkinsci.plugins.configfiles.folder.FolderConfigFileProperty$1"/>
>> New config.xml shows this comparator: > class="org.jenkinsci.plugins.configfiles.ConfigComparator"/>
>>
>> I see some commits about pulling ConfigComparator out from where it used 
>> to live, but I'm not sure if that's the exact cause of what's going on here.
>>
>> Thanks,
>> Mike
>>
>

-- 
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/1b986ab7-94fd-416e-bd45-283180bd4f8b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: multi-branch pipeline, shell wrapper script fails

2018-08-28 Thread 'Björn Pedersen' via Jenkins Users
Hi, 
The too many levels of symbolic links normally hints to a symlink circle. 

Carefully check  the workspace folder (and parents) on the host machine.

Björn

Am Dienstag, 28. August 2018 11:58:46 UTC+2 schrieb ga...@ridezum.com:
>
> Here's the condensed output from the build job log...  It's Jenkins 2.140 
> with all of the latest plugins. It seems to be failing to start creating a 
> log while it wraps my shell script. Not sure how to debug this.
>
> [h_ci-cd_dev_2018-08-13-kube-B25Q2OMNNSNLLVD3BXC7FMQBF3IKQYJE4OSTUSVSM65SZ6NCGBAQ]
>  
> Running shell script
> + git rev-parse 78af875366ad95083bc70e1bf98ada278df9d751~
> [Pipeline] stage
> [Pipeline] { (Create Docker images)
> [Pipeline] container
> [Pipeline] {
> [Pipeline] sh
> [h_ci-cd_dev_2018-08-13-kube-B25Q2OMNNSNLLVD3BXC7FMQBF3IKQYJE4OSTUSVSM65SZ6NCGBAQ]
>  
> Running shell script
> sh: 1: touch: Too many levels of symbolic links
> + source /usr/local/awscli/bin/activate
> ++ deactivate nondestructive
> .
> .
> .
> .
> e492023cc4f9: Layer already exists
> cbda574aa37a: Layer already exists
> 8451f9fe0016: Layer already exists
> 858cd8541f7e: Layer already exists
> a42d312a03bb: Layer already exists
> sh: 1: touch: Too many levels of symbolic links
> dd1eb1fd7e08: Layer already exists
> e6a9d89abfe6: Pushed
> sh: 1: touch: Too many levels of symbolic links
> sh: 1: touch: Too many levels of symbolic links
> sh: 1: touch: Too many levels of symbolic links
> c78bbd2f18f1: Pushed
> a795488c6995: Pushed
> sh: 1: touch: Too many levels of symbolic links
> sh: 1: touch: Too many levels of symbolic links
> sh: 1: touch: Too many levels of symbolic links
> sh: 1: touch: Too many levels of symbolic links
> sh: 1: touch: Too many levels of symbolic links
> sh: 1: touch: Too many levels of symbolic links
> wrapper script does not seem to be touching the log file in 
> /home/jenkins/workspace/h_ci-cd_dev_2018-08-13-kube-B25Q2OMNNSNLLVD3BXC7FMQBF3IKQYJE4OSTUSVSM65SZ6NCGBAQ@tmp/durable-9be4cc24
>
>

-- 
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/c60ec88e-8992-475d-a7bf-de7164bddb24%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


  1   2   >