Skip to main content
Question

Workaround for Script Parameter $3?


Forum|alt.badge.img+8

Does anyone know of a workaround to get user input from Self Service either than using the script parameter $3?

We have noticed since the JAMF PRO JSS 10.11.1 update, this is broken. We utilize this parameter heavily when onboarding in August, for about 1200 students and their machines, grabbing their login ID from Self Service to rename their machines. Which puts these computers into special smart groups, which then our JSS syncs with our wireless network access control system for students to gain access to our wireless network. What we are noticing is that instead of $3 outptutting, "ldapuser/ActiveDirectoryUser" it's spitting out "localuser" from the machine.

The latest update for JAMF PRO, 10.12 did not address this. I think JAMF is aware of this, although it isn't listed in known problems.

We are trying to be proactive in the event this isn't fixed by the JAMF devs by August. If anyone has any ideas, it will be appreciated.

Script Parameters

3 replies

leslie_h
Forum|alt.badge.img+14
  • Employee
  • 100 replies
  • May 8, 2019

You can grab the logged in user using either:
/usr/bin/stat -f%Su /dev/console
or
/usr/bin/python -c 'from SystemConfiguration import SCDynamicStoreCopyConsoleUser; import sys; username = (SCDynamicStoreCopyConsoleUser(None, None, None) or [None])[0]; username = [username,""][username in [u"loginwindow", None, u""]]; sys.stdout.write(username + " ");'


Forum|alt.badge.img+10
  • Valued Contributor
  • 55 replies
  • May 8, 2019

@pchang, have you opened a case with Jamf about this issue? Might help to bump it up the priority list if they know it's causing specific problems for you.


Forum|alt.badge.img+8
  • Author
  • Contributor
  • 35 replies
  • June 9, 2019

For those that are curious, here is the product issue number: PI-006954


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings