Skip to content

Instantly share code, notes, and snippets.

@elmodaddyb
Created May 29, 2017 01:58
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save elmodaddyb/427d9c1fb5efcaf68c95070fb606b81d to your computer and use it in GitHub Desktop.
Save elmodaddyb/427d9c1fb5efcaf68c95070fb606b81d to your computer and use it in GitHub Desktop.
Gerbera OSX Launchd
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Disabled</key>
<false/>
<key>Label</key>
<string>gerbera.io</string>
<key>ProgramArguments</key>
<array>
<string>/usr/local/bin/gerbera</string>
<string>--home</string>
<string>/your/gerbera/home</string>
<string>--config</string>
<string>/your/gerbera/config.xml</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>StandardOutPath</key>
<string>/your/gerbera/home/std.out</string>
<key>StandardErrorPath</key>
<string>/your/gerbera/home/std.err</string>
</dict>
</plist>

Create new Launch Agent

^^^^ SEE ABOVE ^^^^

Save Launch Agent

Save to user's launch agent path -->

~/Library/LaunchAgents/gerbera.io.plist

Load the Launch Agent

$ launchctl load ~/Library/LaunchAgents/gerbera.io.plist

Start the Launch Agent

$ launchctl start gerbera.io

Stop the Launch Agent

$ launchctl stop gerbera.io
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment