lockable-resources-plugin
lockable-resources-plugin copied to clipboard
freestyle project: use build parameter as resource
I was a bit surprised to see that variable interpolation does not work for locking resources in a freestyle job. I'ld like to create a mutex around a build parameter value that can be specified by multiple jobs (the value is not known upfront so i cannot hardcode it as resource labels).
In a pipeline job this seems trivial with something like, is there a limitation that this does not work for freestyle jobs?
lock("${env.NODE_NAME}-exclusive") {
//...
}
It's just not implemented - Many things that are trivial in pipeline need special handling in Freestyle jobs... There is an open pull request(#33) to add this feature, though.
Hello, my life depends on this feature. OK, perhaps it's a bit of exaggeration, but I can't solve my issue otherwise. What would it take to make it work?