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

default tools not installed on agent

XMLWordPrintable

    • Declarative - 1.2

      given the following pipeline, I would expect the java version "1.8" to be printed, but this is not the case - instead I get "1.7"; the default version of the underlying system.

      pipeline {
          agent none
          tools {
              jdk "Oracle JDK 1.8 (latest)"
          }    
          stages {
              stage ('prepare') {
                  agent any
                  steps {
                      sh "java -version"
                  }
              }
          }
      }
      

      but this one works as:

      pipeline {
          agent any
          tools {
              jdk "Oracle JDK 1.8 (latest)"
          }    
          stages {
              stage ('prepare') {
                  steps {
                      sh "java -version"
                  }
              }
          }
      }
      

      ...my expectation is, that the tools on top scope are installed on all agents.

            abayer Andrew Bayer
            imod Dominik Bartholdi
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: