@cryptotaxi247 / netdata-1 / commits / af798e3b9

fix installing service file and start/stop ND using `launchctl` on macOS (#16693)

* fix path to netdata.plist * add "do not fork" arg to netdata.plist

Ilya Mashchenko committed Dec 29, 2023 at 15:52 UTC af798e3b94123979f0011e0f385b1c46a78466fc
2 files changed +2 -1
system/install-service.sh.in
+1 -1
@@ -625,7 +625,7 @@ freebsd_cmds() {
625
626 install_darwin_service() {
627 info "Installing macOS plist file for launchd."
628 - if ! install -C -S -p -m 0644 -o 0 -g 0 system/launchd/netdata.plist /Library/LaunchDaemons/com.github.netdata.plist; then
628 + if ! install -C -S -p -m 0644 -o 0 -g 0 "${SVC_SOURCE}/launchd/netdata.plist" /Library/LaunchDaemons/com.github.netdata.plist; then
629 error "Failed to copy plist file."
630 exit 4
631 fi
system/launchd/netdata.plist.in
+1
@@ -8,6 +8,7 @@
8 <key>ProgramArguments</key>
9 <array>
10 <string>@sbindir_POST@/netdata</string>
11 + <string>-D</string>
12 </array>
13 <key>RunAtLoad</key>
14 <true/>