Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-14904

[GSS](7.1.z) elytron-tool.sh script detects JBOSS_HOME incorrectly

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 7.1.4.CR1, 7.1.4.GA
    • 7.1.2.GA
    • Scripts
    • None

      If JBOSS_HOME is set then :

      Running $JBOSS_HOME/bin/elytron-tool.sh results in a warning:
      WARNING JBOSS_HOME may be pointing to a different installation - unpredictable results may occur.

      This script has two issues :
      It sets SANITIZED_JBOSS_HOME to $JBOSS_HOME/.. instead of $JBOSS_HOME
      It compares RESOLVED_JBOSS to SANITIZED_JBOSS_HOME, instead of RESOLVED_JBOSS_HOME

      Current elytron-tool.sh :
      ----------------------------------------------------------------------------------

      RESOLVED_JBOSS_HOME=`cd "$DIRNAME/.."; pwd`
      if [ "x$JBOSS_HOME" = "x" ]; then

      JBOSS_HOME=$RESOLVED_JBOSS_HOME
      else
      SANITIZED_JBOSS_HOME=`cd "$JBOSS_HOME/.."; pwd`
      if [ "$RESOLVED_JBOSS" != "$SANITIZED_JBOSS_HOME" ]; then
      echo "WARNING JBOSS_HOME may be pointing to a different installation - unpredictable results may occur."
      echo ""
      fi
      fi
      export JBOSS_HOME
      ---------------------------------------------------------------------------------

      Expected elytron-tool.sh
      ---------------------------------------------------------------------------------

      RESOLVED_JBOSS_HOME=`cd "$DIRNAME/.."; pwd`
      if [ "x$JBOSS_HOME" = "x" ]; then

      JBOSS_HOME=$RESOLVED_JBOSS_HOME
      else
      SANITIZED_JBOSS_HOME=`cd "$JBOSS_HOME"; pwd`
      if [ "$RESOLVED_JBOSS_HOME" != "$SANITIZED_JBOSS_HOME" ]; then
      echo "WARNING JBOSS_HOME may be pointing to a different installation - unpredictable results may occur."
      echo ""
      fi
      fi
      export JBOSS_HOME
      ------------------------------------------------------------------------------

              pjindal@redhat.com Paramvir Jindal
              pjindal@redhat.com Paramvir Jindal
              Peter Mackay Peter Mackay
              Peter Mackay Peter Mackay
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: