Uploaded image for project: 'SET - Setups'
  1. SET - Setups
  2. SET-105

Setup should offer an alternative to use of "sudo -E"

    XMLWordPrintable

Details

    • Feature
    • Status: Released (View Workflow)
    • Minor
    • Resolution: Fixed
    • 1.9, 1.10, 1.11
    • 1.11.5, 1.12

    Description

      Current Situation

      • All JobScheduler setups use "sudo -E" to run the installer for the environment of the current user, i.e. creating the contents of the installation directory for the root user (or some similar privleged user) and creating the contents of the configuration directory for the current user.
      • This mechanism has been introduced with the early days of JobScheduler to ensure that the $SUDO_USER environment variable shows the account of the caller.
        • For sudo releases 1.6.9 - and possibly with specific platforms as Solaris - this environment variable had to be enforced by use of "sudo -E".
        • With sudo releases 1.7.6 and later (tested up to 1.8.6) this environment variable is anyway set therefore there is no further need for "sudo -E".
      • This sudo option works fine. However, it creates some hazzle for larger organizations that force users to modify the sudoers file to allow "java -jar ...". In addition the name of the .jar archive with the installer is specific for each release which requires the sudoers file to be modified accordingly for each release.

      Desired Behavior

      • The "sudo -E" setting should not be used by default but should be optionally maintained as it works for most environments.

      Workaround

      • You can test if your sudo version when used without the -E option writes the account of the caller to the $SUDO_USER environment variable with
        sudo printenv | grep SUDO_USER
        
      • if the environment variable is populated accordingly then modify setup.sh for any installer, e.g. JobScheduler Master, JOC Cockpit, in line 123 to replace my_sudo with sudo

      Attachments

        There are no Sub-Tasks for this issue.

        Activity

          People

            oh Oliver Haufe
            ap Andreas PĆ¼schel
            Mahendra Patidar Mahendra Patidar
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 1 day
                1d
                Remaining:
                Remaining Estimate - 1 day
                1d
                Logged:
                Time Spent - Not Specified
                Not Specified