Installing GlobalProtect and copying plist to $USER preferences library
08/08/2018 1047 views
I can install the globalprotect pkg with the k1000 without issue, but I just cannot get the plist for it set or deployed.
I've tried with kscript and shell script.
I've installed the globalprotect software and configured the portal and settings for our org, then I copied the two plist files created in the user's preferences.
I zipped up GlobalProtect.pkg, com.paloaltonetworks.GlobalProtect.plist, and com.paloaltonetworks.GlobalProtect.settings.plist to GlobalProtectMacs.zip. I associated this file with the k1000 software inventory item and then used the following custom command on the managed installation:
sudo cp -R com.paloaltonetworks.GlobalProtect* /Users/$USER/Library/Preferences/ && sudo installer -pkg GlobalProtect.pkg -target /
I can manually run the following from terminal and all works, but I can't get the k1000 to do it on its own.
sudo cp -R com.paloaltonetworks.GlobalProtect* ~/Library/Preferences/ && sudo installer -pkg GlobalProtect.pkg -target /
Any suggestions much appreciated. Thanks.
Answer Chosen by the Author
Please log in to answer
I don't have any experience with Macs, but I think the issue is that Managed Installs always run as System (on Windows) or the Mac equivalent on Macs. Since you're using the $USER variable, you would need to have KACE run the command as the logged in user, which is an option only available on a KACE Script. Try running the command from a Script as the logged in user, and I think it should work.
Answered 08/09/2018 by: ondrar