if there are two tools in Jenkinsfile they are ignored, it works with just one

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

    • Type: Bug
    • Resolution: Cannot Reproduce
    • Priority: Major
    • Environment:
      Jenkins Version 2.394
      NodeJS Plugin Version 1.6.0
      OS: Linux - 3.10.0-1160.83.1.el7.x86_64
      Java: 11.0.18 - Red Hat, Inc. (OpenJDK 64-Bit Server VM)

      If I have two tools defined, as in the code below. The tools are completely ignored (the version step prints the default tools). If I have just one tools defined (either jdk or nodejs) then it works fine, and that defined tool has the right version (the other one of course has the default version).

      Having two tools worked perfectly fine for years, but it fails in the recent version of Jenkins.

       

      pipeline {
          agent any
          tools {
              jdk "8u152"
              nodejs "Node LTS"
          }
          stages {
              stage('checkout') {
                  steps {
                      checkout([$class: 'GitSCM', branches: scm.branches, extensions: scm.extensions,
                      userRemoteConfigs: scm.userRemoteConfigs])
                  }
              }
              stage('Version Check') {
                  steps {
                      sh "java -version"
                      sh 'node -v'
                      sh 'npm -v'
                  }
              }
          }
      }
      

       

        1. plugins.txt
          2 kB
          Mark Waite
        2. run-jenkins.sh
          0.9 kB
          Mark Waite
        3. root-config.xml
          0.5 kB
          Mark Waite
        4. job-config.xml
          1 kB
          Mark Waite
        5. build.xml
          21 kB
          Ariel
        6. plugins-system.txt
          5 kB
          Ariel

            Assignee:
            Unassigned
            Reporter:
            Ariel
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: