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

JENKINS_HOME variable ignored in tomcat context

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Critical Critical
    • core
    • None
    • Jenkins 2.332.1, Tomcat 9, RHEL 7

      Attempting to replace jenkins.war to upgrade from 2.319.3 to 2.332.1

      A context file specifies Jenkins home.
      <Context docBase="jenkins">
      <Environment name="JENKINS_HOME" value="/opt/jenkins_home/" type="java.lang.String"/>
      </Context>

       

      instead of the recently updated Jenkins using the specified JENKINS_HOME it's using the tomcat user's home/.jenkins 

       

      Reverting to the previous version resolves the issue.

          [JENKINS-68120] JENKINS_HOME variable ignored in tomcat context

          Basil Crow added a comment -

          Duplicates JENKINS-68081.

          This content has been recently added to the upgrade guide in jenkins-infra/jenkins.io#5020 and should appear on jenkins.io shortly:

          JNDI setting of Jenkins home directory removed

          Support for setting the Jenkins home directory via Java Naming and Directory Interface (JNDI) has been removed in jenkinsci/jenkins#6111.

          The Jenkins home directory may still be set using the -DJENKINS_HOME Java system property or the JENKINS_HOME environment variable.

          Users who load jenkins.war via a servlet container like Tomcat should refer to their servlet container's documentation for information on how to customize Java system properties or environment variables.

          For example, the Tomcat servlet container accepts custom Java system properties in the CATALINA_OPTS environment variable.

          Basil Crow added a comment - Duplicates JENKINS-68081 . This content has been recently added to the upgrade guide in jenkins-infra/jenkins.io#5020 and should appear on jenkins.io shortly: JNDI setting of Jenkins home directory removed Support for setting the Jenkins home directory via Java Naming and Directory Interface (JNDI) has been removed in jenkinsci/jenkins#6111 . The Jenkins home directory may still be set using the -DJENKINS_HOME Java system property or the JENKINS_HOME environment variable. Users who load jenkins.war via a servlet container like Tomcat should refer to their servlet container's documentation for information on how to customize Java system properties or environment variables. For example, the Tomcat servlet container accepts custom Java system properties in the CATALINA_OPTS environment variable.

            Unassigned Unassigned
            mpartridge Matt Partridge
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: