aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLiam Mitchell <[email protected]>2025-03-05 02:33:21 +0000
committerLiam Mitchell <[email protected]>2025-03-05 02:33:21 +0000
commit2b823aa2088587575f62784c150af75c2535618b (patch)
tree54cf2adb63dec15affcdb796335b472d19e06bac /src
parentInitial implementation of service status reporting (diff)
downloadzen-2b823aa2088587575f62784c150af75c2535618b.tar.xz
zen-2b823aa2088587575f62784c150af75c2535618b.zip
Update Linux service type and add libsystemd dependency
Diffstat (limited to 'src')
-rw-r--r--src/zenserver/main.cpp4
-rw-r--r--src/zenutil/service.cpp2
2 files changed, 5 insertions, 1 deletions
diff --git a/src/zenserver/main.cpp b/src/zenserver/main.cpp
index 636e7f6c1..9ae54bdf1 100644
--- a/src/zenserver/main.cpp
+++ b/src/zenserver/main.cpp
@@ -34,6 +34,10 @@
# include "windows/service.h"
#endif
+#if ZEN_PLATFORM_LINUX
+# include <systemd/sd-daemon.h>
+#endif
+
//////////////////////////////////////////////////////////////////////////
// We don't have any doctest code in this file but this is needed to bring
// in some shared code into the executable
diff --git a/src/zenutil/service.cpp b/src/zenutil/service.cpp
index c156b001c..ea7c2aae6 100644
--- a/src/zenutil/service.cpp
+++ b/src/zenutil/service.cpp
@@ -334,7 +334,7 @@ namespace {
"StartLimitIntervalSec=0\n"
"\n"
"[Service]\n"
- "Type=simple\n"
+ "Type=notify\n"
"Restart=always\n"
"RestartSec=1\n"
"User={}\n"