]> git.proxmox.com Git - pve-lxc-syscalld.git/commitdiff
finish service file
authorWolfgang Bumiller <w.bumiller@proxmox.com>
Wed, 22 Jan 2020 09:59:08 +0000 (10:59 +0100)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Wed, 22 Jan 2020 10:05:50 +0000 (11:05 +0100)
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
etc/pve-lxc-syscalld.service.in
src/main.rs

index b1d707a1c0110d6000aa25adaf7cd1febfcb5fb8..be076a70548f56b8d7d48a3bba25d8b548fee3d2 100644 (file)
@@ -3,9 +3,9 @@ Description=Proxmox VE LXC Syscall Daemon
 Before=pve-guests.service
 
 [Service]
-#FIXME!!!
-Type=simple
-ExecStart=%LIBEXECDIR%/pve/pve-lxc-syscalld
+Type=notify
+ExecStart=%LIBEXECDIR%/pve-lxc-syscalld/pve-lxc-syscalld --system /run/pve/lxc-syscalld.sock
+RuntimeDirectory=pve
 Restart=on-failure
 
 [Install]
index 640580634f9521eb1a2c301d2f2212a67a6697a8..2f80ef9b83e329577adf2f416ead039ed3494727 100644 (file)
@@ -128,7 +128,7 @@ extern "C" {
 
 fn notify_systemd() -> StdIo::Result<()> {
     let err = unsafe { sd_notify(0, c_str!("READY=1\n").as_ptr()) };
-    if err == 0 {
+    if err >= 0 {
         Ok(())
     } else {
         Err(StdIo::Error::from_raw_os_error(-err))