Uploaded image for project: 'Grouper'
  1. Grouper
  2. GRP-2758

gsh.sh should run as user tomcat with all env vars used in tomcat

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 2.5.28
    • None
    • None

    Description

      this is a starting point, add this to gsh.sh

       

      if [ -z "$GROUPER_GSH_CHECK_USER" ]
        then
          if [ -f /usr/local/bin/grouperEnv.sh ] 
            then
              . /usr/local/bin/grouperEnv.sh
          fi
      fi
       
       
      if [ "$GROUPER_GSH_CHECK_USER" = "true"  ]
        then
          username=$(whoami)
          if [ "$GROUPER_GSH_USER" != "$username"  ]
            then
              echo "ERROR: User is '$username' but should be '$GROUPER_GSH_USER'!  sudo -u $GROUPER_GSH_USER /bin/bash      and then run gsh.sh"
              exit 1
          fi
          if [ -z "$JAVA_HOME" ] 
            then
              if [ -f /etc/bashrc ] 
                then
                  . /etc/bashrc
              fi
          fi
      fi
       
       

      Attachments

        Activity

          People

            chris.hyzer@at.internet2.edu Chris Hyzer (upenn.edu)
            chris.hyzer@at.internet2.edu Chris Hyzer (upenn.edu)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Smart Checklist