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

Unreliable defaulting of Jenkins.workspaceDir

    XMLWordPrintable

Details

    Description

      Jenkins.workspaceDir is supposed to default to $JENKINS_HOME/workspace/ on new installations: the "modern" location, consistent with that of slaves. But if you do not save the Jenkins global configuration during the first startup, on the next startup $JENKINS_HOME/jobs/ exists yet $JENKINS_HOME/config.xml does not, so the "compatibility" code kicks in and the old location is used!

      Just setting this field to the new value in the instance initializer probably does not suffice, since installations upgraded from before the introduction of this field would be incorrectly switched to the new value.

      Probably suffices to adjust the check to also check for the existence of $JENKINS_HOME/config.xml, since most old installations would have saved this file at least once.

      Attachments

        Issue Links

          Activity

            jglick Jesse Glick created issue -
            jglick Jesse Glick made changes -
            Field Original Value New Value
            Link This issue is blocking JENKINS-8446 [ JENKINS-8446 ]
            danielbeck Daniel Beck made changes -
            Link This issue is related to SECURITY-129 [ SECURITY-129 ]
            rtyler R. Tyler Croy made changes -
            Workflow JNJira [ 154019 ] JNJira + In-Review [ 178658 ]
            danielbeck Daniel Beck made changes -
            Link This issue is duplicated by JENKINS-39670 [ JENKINS-39670 ]
            jglick Jesse Glick made changes -
            Link This issue relates to JENKINS-38837 [ JENKINS-38837 ]
            jglick Jesse Glick made changes -
            Link This issue relates to JENKINS-50164 [ JENKINS-50164 ]
            batmat Baptiste Mathus made changes -
            Assignee Baptiste Mathus [ batmat ]
            batmat Baptiste Mathus made changes -
            Labels upgrade workspace essentials upgrade workspace
            batmat Baptiste Mathus made changes -
            Sprint Essentials - Milestone 1 [ 511 ]
            batmat Baptiste Mathus made changes -
            Link This issue relates to JENKINS-50164 [ JENKINS-50164 ]
            batmat Baptiste Mathus made changes -
            Status Open [ 1 ] In Progress [ 3 ]
            batmat Baptiste Mathus made changes -
            Labels essentials upgrade workspace upgrade workspace
            batmat Baptiste Mathus made changes -
            Sprint Essentials - Milestone 1 [ 511 ]
            batmat Baptiste Mathus made changes -
            Assignee Baptiste Mathus [ batmat ]
            batmat Baptiste Mathus made changes -
            Link This issue relates to JENKINS-50164 [ JENKINS-50164 ]
            jglick Jesse Glick made changes -
            Link This issue relates to JENKINS-53284 [ JENKINS-53284 ]
            jglick Jesse Glick made changes -
            Link This issue relates to JENKINS-54654 [ JENKINS-54654 ]
            batmat Baptiste Mathus made changes -
            Status In Progress [ 3 ] Open [ 1 ]
            smasher Daniel Estermann made changes -
            Link This issue is related to JENKINS-60969 [ JENKINS-60969 ]

            People

              Unassigned Unassigned
              jglick Jesse Glick
              Votes:
              5 Vote for this issue
              Watchers:
              20 Start watching this issue

              Dates

                Created:
                Updated: