The goal here is to have an OSX pagekite backend run automatically when the system starts up. Inspired by the DebianPackage, these instruction put pagekite.py in /usr/bin and the config file at /etc/pagekite/pagekite.rc.
Download pagekite.py. You'll need to change the permissions to make it system runnable, and then put it in /usr/bin.
wget --no-check-certificate http://pagekite.net/pk/pagekite.py chmod +x pagekite.py sudo chown root:wheel pagekite.py mv pagekite.py /usr/bin/pagekite.py
Download a sample pagekite.rc config file, or configure one however you like - nothing special should need to be changed for OSX.
mkdir /etc/pagekite/ mv .pagekite.rc /etc/pagekite/pagekite.rc
Now add pagekite.py as a launchctl service, pointing it to the options file:
sudo launchctl submit -l pagekite -- pagekite.py --clean -o /etc/pagekite/pagekite.rc
Now that it's installed with launchctl, pagekite.py should start whenever the system boots up, and even if pagekite.py crashes it should be restarted. These commands may be helpful:
sudo launchctl start pagekite sudo launchctl stop pagekite sudo launchctl remove pagekite
[ Back to How-Tos ]