title: How do I retrieve the remote FS root from declarative Jenkinsfile?
body: <p>I have a heavyweight base project that rarely changes over time and has a lot of header files. I've set it up to be built in a custom workspace with a relative path <code>base</code>. So on a <em>remote</em> node with FS root set to <code>C:\Jenkins</code>, the resulting path on that particular node will be <code>C:\Jenkins\base</code>.
  The reason for this setup is that I don't want to copy or unpack the whole base project for every dependent project to save build time. Also, I don't want to use absolute paths because I like the idea of a self-contained jenkins installation.</p>
  
  <p>Now I have a second project <code>project</code> that uses <code>base</code>. I need to specify the path of <code>base</code> to the build system of <code>project</code> so that it will find the <code>base</code> headers it needs.</p>
  
  <p>Is there any way to retrieve the remote FS root through the environment? I've tried using <code>${env.JENKINS_HOME}</code> but this always resolves to the home folder of the Jenkins master. My build system expects to find the path to the <code>base</code> project in the PATH_TO_BASE environment variable:</p>
  
  <pre><code>pipeline {
      agent none
  
      stages {
          stage('Build') {
              parallel {
                  stage('Build Linux x64') {
                      agent {
                          label "Debian9_x64"
                      }
                      steps {
                          withEnv(["PATH_TO_BASE=${env.JENKINS_HOME}/base"]) {
                              sh '''mkdir -p _build
                              cd _build
                              cmake ..
                              cmake --build .'''
                          }
                      }
                  }
                  stage('Build Windows10') {
                      agent {
                          label "Windows10"
                      }
                      steps {
                          withEnv(["PATH_TO_BASE=${env.JENKINS_HOME}/base"]) {
                              bat '''if not exist _build mkdir _build
                              cd _build
                              cmake ..
                              cmake --build .'''
                          }
                      }
                  }
              }
          }  
      }
  }
  </code></pre>