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

Workspace is set incorrectly for the job with whitespaces in its name

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • kubernetes-plugin
    • None
    • Jenkins 2.32.1
      Kubernetes plugin: 0.10

      Example:
      Create pipeline job named "i like spaces":

      podTemplate(label: 'app', containers: [containerTemplate(name: 'docker', image: 'docker:1.11', ttyEnabled: true, command: 'cat')]) {
          node('app') {
                  container('docker') {
                          sh 'pwd'
                  }
          }
      }
      

      ER: Output includes "/home/jenkins/workspace/i like spaces"
      AR: Output includes "/home/jenkins"
      Workaround: rename job to exclude spaces (i.e. "i_like_underscores")

          [JENKINS-41287] Workspace is set incorrectly for the job with whitespaces in its name

          Roman Safronov created issue -
          Roman Safronov made changes -
          Description Original: Example:
          Create pipeline job named "i like spaces":
          {code}
          podTemplate(label: 'app', containers: [containerTemplate(name: 'docker', image: 'docker:1.11', ttyEnabled: true, command: 'cat')]) {
              node('app') {
                      container('docker') {
                              sh 'pwd'
                      }
              }
          }
          {code}
          ER: Output include "/home/jenkins/workspace/i like spaces"
          AR: Output includes "/home/jenkins"
          Workaround: rename job to exclude spaces (i.e. "i_like_underscores")
          New: Example:
          Create pipeline job named "i like spaces":
          {code}
          podTemplate(label: 'app', containers: [containerTemplate(name: 'docker', image: 'docker:1.11', ttyEnabled: true, command: 'cat')]) {
              node('app') {
                      container('docker') {
                              sh 'pwd'
                      }
              }
          }
          {code}
          ER: Output includes "/home/jenkins/workspace/i like spaces"
          AR: Output includes "/home/jenkins"
          Workaround: rename job to exclude spaces (i.e. "i_like_underscores")
          Carlos Sanchez made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

            csanchez Carlos Sanchez
            electroma Roman Safronov
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: