cloud.tytik.netcheck.plist
52 Zeilen · 1.6 KB · XML
| 1 | |
| 2 | |
| 3 | <!-- |
| 4 | launchd-Job fuer netcheck.sh auf macOS. |
| 5 | |
| 6 | Installation (als root, damit mtr Raw Sockets oeffnen darf): |
| 7 | sudo cp cloud.tytik.netcheck.plist /Library/LaunchDaemons/ |
| 8 | sudo chown root:wheel /Library/LaunchDaemons/cloud.tytik.netcheck.plist |
| 9 | sudo chmod 644 /Library/LaunchDaemons/cloud.tytik.netcheck.plist |
| 10 | sudo launchctl load -w /Library/LaunchDaemons/cloud.tytik.netcheck.plist |
| 11 | |
| 12 | Deinstallation: |
| 13 | sudo launchctl unload -w /Library/LaunchDaemons/cloud.tytik.netcheck.plist |
| 14 | |
| 15 | Pfad in ProgramArguments an den tatsaechlichen Ablageort anpassen. |
| 16 | --> |
| 17 | <plist version="1.0"> |
| 18 | <dict> |
| 19 | <key>Label</key> |
| 20 | <string>cloud.tytik.netcheck</string> |
| 21 | |
| 22 | <key>ProgramArguments</key> |
| 23 | <array> |
| 24 | <string>/usr/local/netcheck/netcheck.sh</string> |
| 25 | <string>run</string> |
| 26 | </array> |
| 27 | |
| 28 | <!-- alle 300 Sekunden --> |
| 29 | <key>StartInterval</key> |
| 30 | <integer>300</integer> |
| 31 | |
| 32 | <key>RunAtLoad</key> |
| 33 | <true/> |
| 34 | |
| 35 | <key>StandardOutPath</key> |
| 36 | <string>/var/log/netcheck-launchd.log</string> |
| 37 | <key>StandardErrorPath</key> |
| 38 | <string>/var/log/netcheck-launchd.log</string> |
| 39 | |
| 40 | <key>EnvironmentVariables</key> |
| 41 | <dict> |
| 42 | <key>PATH</key> |
| 43 | <string>/opt/homebrew/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin</string> |
| 44 | </dict> |
| 45 | |
| 46 | <!-- Verhindert, dass der Job bei Ressourcenknappheit gedrosselt wird --> |
| 47 | <key>LowPriorityIO</key> |
| 48 | <false/> |
| 49 | <key>Nice</key> |
| 50 | <integer>0</integer> |
| 51 | </dict> |
| 52 | </plist> |