Posted on 08-01-2017 10:13 AM
Hello!
I'm trying to find a solution for attaching Dockutil commands to a policy. I want to embed the command within the policy, instead of creating a separate script for just adding one icon to the dock. I expected to be able to make a one-banger command on a per-Application basis through Files and Processes > Execute Command within the policy options, but I haven't yet been successful.
Here's what I'm throwing in now. I don't know how the syntax compares to creating a bash script. I think my hangup revolves around the command running as Sudo, instead of the current user.
/usr/local/bin/dockutil --add /Applications/DaVinci Resolve/DaVinci Resolve.app --before 'Fusion' "/Users/$3"
Fomr the logs...
Running command /usr/local/bin/dockutil --add /Applications/DaVinci Resolve/DaVinci Resolve.app --before 'Fusion' "/Users/$3"... Result of command: /Users/Library/Preferences/com.apple.dock.plist does not seem to be a home directory or a dock plist
Right now I'm just testing this with an ongoing policy triggered by Self Service. The application I'm deploying (DaVinci) takes too long for this to reasonably be deployed as a login item, so I think I'll ultimately set it to recurring/once per user. That way, they'll already be logged in when it runs.
Any recommendations?
Solved! Go to Solution.
Posted on 08-01-2017 10:21 AM
Right after I posted this, I changed the last bit of the command and got it working :)
..... --before 'Fusion' "/Users/$3"
changed to
..... --before 'Fusion' --allhomes
Posted on 08-01-2017 10:21 AM
Right after I posted this, I changed the last bit of the command and got it working :)
..... --before 'Fusion' "/Users/$3"
changed to
..... --before 'Fusion' --allhomes
Posted on 08-01-2017 10:21 AM
[deleted double post]