Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-45812

Unable to create pipeline job from a template with "using" keyword

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • job-dsl-plugin
    • CloudBees Jenkins Enterprise 2.46.3.2-rolling
      Latest job-dsl version (1.64)

      I have the following dsl:

      pipelineJob("hello-pipeline") {

           using("/templates/hello") // where hello is a pipeline job
      }

      Got this exception:

      java.lang.NullPointerExceptionat javaposse.jobdsl.plugin.ExecuteDslScripts.updateTemplates(ExecuteDslScripts.java:380)at javaposse.jobdsl.plugin.ExecuteDslScripts.perform(ExecuteDslScripts.java:322)

      Looking at the source, this line seems to be the culprit:

      AbstractProject templateProject = getLookupStrategy().getItem(seedJob, templateName, AbstractProject.class);

        

            daspilker Daniel Spilker
            ctran Cuong Tran
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: