Im using version 1.83 of the plugin and jenkins 2.387.2. This jobdsl does not work:
node() {
git branch: "myjenkins", credentialsId: "my-credentials", url: "ssh://
mygerrit.com:29418/jenkins/jobdsl-scripts"
jobDsl targets: "src/jobs/groovy/*.groovy",
additionalParameters: [
disable_jobs: false,
],
ignoreMissingFiles: true,
ignoreExisting: false,
removedJobAction: RemovedJobAction.DELETE,
removedViewAction: RemovedViewAction.DELETE,
lookupStrategy: LookupStrategy.JENKINS_ROOT,
additionalClasspath: "src/jobs"
}
The groovy dsl-files under src/jobs/groovy then import the class lib.Helper
Which is a file named Helper.groovy located in the src/jobs/lib folder.
But when running this, it complains that it can not find the class lib.Helper.
Im out of ideas to try. It works on another jenkins we are running.