Skip to main content
Question

Running scripts as admin

  • May 29, 2026
  • 4 replies
  • 51 views

Forum|alt.badge.img

I am trying to install sophos through JAMF School and used their script.
The script it working fine when running it on the mac as sudo, but when i try pushing it through JAMF, nothing happens.

This makes me wonder if i am missing something, i seem to be unable to make the app run as an administrator/sudo user.


Can anyone help?

4 replies

Jay-payglocal
Forum|alt.badge.img

Go through these in order:

  1. Remove all sudo usage
  2. Add logging to script
  3. Use absolute paths
  4. Verify JAMF policy execution
  5. Check /var/log/jamf.log
  6. Confirm Sophos installer doesn't need UI
  7. Try PKG deployment instead of script

agungsujiwo
Forum|alt.badge.img+9
  • Contributor
  • May 29, 2026

Is this the script you are using, and are you running macOS Tahoe?
 

 

 


thebrucecarter
Forum|alt.badge.img+16

As ​@Jay-payglocal  mentions above, make no assumptions about paths or environment variables, or anything else that might be set up in a local user Terminal session.


Forum|alt.badge.img
  • Author
  • New Contributor
  • June 1, 2026

Is this the script you are using, and are you running macOS Tahoe?
 

 

 

Yes, it is. And yes, we are running the newest OS (Tahoe i think).