Many users have asked if we have scripts that would automatically lock the worker when a user logs in, and unlock it when they log out. Here's how.
- ensure that no other copies of
com.pipelinefx.WorkerLock.plist
exist in any of these directories:
/System/Library/LaunchAgents
/Library/LaunchAgents
or the user's ~/Library/LaunchAgents
directories
- install com.pipelinefx.WorkerLock.plist into
/Library/LaunchAgents
- install workerLock.py into
/Applications/pfx/qube/scripts
- fix the permissions on both of these files by running the following commands at a terminal prompt:
sudo chmod 644 /Library/LaunchAgents/com.pipelinefx.WorkerLock.plist
sudo chown root /Library/LaunchAgents/com.pipelinefx.WorkerLock.plist
sudo chgrp wheel /Library/LaunchAgents/com.pipelinefx.WorkerLock.plist
sudo chmod 755 /Applications/pfx/qube/scripts/workerLock.py
sudo chown root /Applications/pfx/qube/scripts/workerLock.py
sudo chgrp admin /Applications/pfx/qube/scripts/workerLock.py
- test the permissions and ownership:
ls -l /Library/LaunchAgents/com.pipelinefx.WorkerLock.plist /Applications/pfx/qube/scripts/workerLock.py
It should return something like:
-rwxr-xr-x@ 1 root admin 2721 Mar 28 13:43 /Applications/pfx/qube/scripts/workerLock.py
-rw-r--r-- 1 root wheel 685 Mar 28 13:00 /Library/LaunchAgents/com.pipelinefx.WorkerLock.plist
You're most interested in the values in the first column (the permissions for user, group, and other), and the owner (root) and group (admin or wheel).
Logout and back in to test, checking the worker lock status from another machine.