I think this will be something simple.
I frequently have policies that run scripts and It seems that I get a lot of policy errors even though the script exit code is 0. It seems that the jss does not expect any output from the script in the "Script Result", and if it gets it, it will report an error. I would want it to report an error if the script exits with a code other than 0.
Anyone care to explain what I'm doing wrong and what I should do?
Here's a partial example of a JSS policy error e-mail I get.
An error occurred executing the policy "Run Script netrenderzombie_c4dr13.sh" on the computer "2939-mp".
Event log from the policy:
/usr/sbin/jamf is version 8.51
Executing Policy Run Script netrenderzombie_c4dr13.sh...
Mounting afp://jss.company.com/CasperShare to /Volumes/CasperShare...
Running Script netrender_c4dr13.sh...
Script Exit Code:0
Script Result: Creating user netrender...
Sat Aug 18 19:43:59 2939-mp.company.com osascript[4866] <Warning>: 3891612: (connectAndCheck) Untrusted apps are not allowed to connect to or launch Window Server before login.
Sat Aug 18 19:43:59 2939-mp.company.com osascript[4866] <Error>: kCGErrorFailure: Set a breakpoint @ CGErrorBreakpoint() to catch errors as they are logged.