Posted on 05-05-2021 02:49 AM
Hello,
in my company we would like to have the possibility to give users temporary admin rights on their Macs, for this I have already found this script : https://github.com/jamf/MakeMeAnAdmin
but unfortunately the currently logged in user is not promoted to admin and i can't find the error or what it could be.
Can this be due to Big Sur? we are also using mobile accounts, if this is important.
I'm still new to policies in connection with scripts,Jamf was practically inherited to me. I would be incredibly happy about any help.
Thanks in advance! :)
Posted on 05-05-2021 03:15 AM
Have a look at the Privileges app
https://github.com/SAP/macOS-enterprise-privileges
Posted on 05-05-2021 06:32 AM
This is my script to promote a user as admin:
dseditgroup -o edit -a "$(who | awk '/console/{ print $1 }')" -t user admin
exit 0
Posted on 05-05-2021 06:33 AM
To remove a user as admin you have to remove that user from the admin group. sudo dseditgroup -o edit -d UserName -t user admin
Posted on 05-05-2021 06:46 AM
If you did deploy that script you found as a policy, what do the policy logs show if there were any errors?