Re: Locking multiple stages with NODE_NAME based lock

2019-04-03 Thread Dusan Nikolov
similar thread > <https://groups.google.com/d/msg/jenkinsci-users/41bKAIfrPAw/zpuyg__7AAAJ>. > Does lock work inside a steps block? Or a script block? It seems like it > should, because it is a step that does something imperatively. > > On Thursday, March 7, 2019 at 3:58:59

Re: Jenkins Declarative Pipeline: Lock multiple stages using NODE_NAME as resource.

2019-03-11 Thread Dusan Nikolov
ssues.jenkins-ci.org/browse/JENKINS-43336 On Monday, March 11, 2019 at 5:58:00 AM UTC-7, Mark Lübbehüsen wrote: > > Hi, > > after downloading the Lockable Resource Plugin in Jenkins, you have to > configure it in the system configuration of jenkins. > > > > Am Fre

Jenkins Declarative Pipeline: Lock multiple stages using NODE_NAME as resource.

2019-03-07 Thread Dusan Nikolov
Hi, I'm trying to lock multiple stages in a pipeline and would like to use NODE_NAME as the resource. Purpose is to allow multiple parallel executions of the pipeline on different available nodes, but to make a node unavailable while it's used by one running pipeline instance. Now, the trick is

Locking multiple stages with NODE_NAME based lock

2019-03-07 Thread Dusan Nikolov
Hi, I'm trying to figure out how/if it's possible to create a lock that will guard multiple stages of a pipeline execution, based on the NODE_NAME on which they are supposed to execute. I tried putting the lock in the options block of the surrounding stage, but this throws an error because opt