jamfHelper Script works locally, breaks when run by policy

cacsj
New Contributor

When running this script locally or with a manual policy trigger, it works fine, waiting for the user to click the button before exiting.

When the script is run with Casper Remote or by policy using any trigger except for manual, it does not wait for the user to click the button before exiting.

What am I missing?

#!/bin/bash
# waitExample.sh

click_value=`/Library/Application Support/JAMF/bin/jamfHelper.app/Contents/MacOS/jamfHelper -windowType hud -timeout 3600 -description "Click the button." -icon /Library/Application Support/JAMF/bin/jamfHelper.app/Contents/Resources/Message.png -button1 'Click Me'`

if [ "$click_value" == "0" ]; then
    echo "User clicked button."
fi

exit 0
4 REPLIES 4

ImAMacGuy
Valued Contributor II

I'm having the same problem on 8.6 with my JH scripts.

paulaust
New Contributor

Was there ever a resolution to this problem. I am experiencing it as well.

paulaust
New Contributor

Was there ever a resolution to this problem. I am experiencing it as well.

lisacherie
Contributor II

Add the following to the line where you call jamf helper

-startlaunchd