]> err.no Git - systemd/commitdiff
Fall back to init script based reload if the .service file doesn't support it.
authorTollef Fog Heen <tfheen@err.no>
Wed, 8 Jun 2011 14:23:22 +0000 (16:23 +0200)
committerTollef Fog Heen <tfheen@err.no>
Wed, 8 Jun 2011 14:23:22 +0000 (16:23 +0200)
debian/changelog
debian/init-functions

index 625f1588d0a8a52873232f1552b5b45121d8829e..8586fc1316f907db1ea77bbb2e83f92c318c67c5 100644 (file)
@@ -1,6 +1,8 @@
 systemd (28-1) UNRELEASED; urgency=low
 
   * New upstream version.
+  * Fall back to the init script reload function if a native .service file
+    doesn't know how to reload.  Closes: #628186
 
  -- Tollef Fog Heen <tfheen@debian.org>  Wed, 08 Jun 2011 16:14:31 +0200
 
index ab8a04fef16a85cd1a78c15b717402183eed3cf1..492cad2436865335498bece0f8b36c3540ed45bf 100644 (file)
@@ -35,6 +35,11 @@ if [ -e /sys/fs/cgroup/systemd ] ; then
                        ;;
                esac
                ;;
+            # Some services can't reload through the .service file,
+            # but can through the init script.
+           if [ "$(systemctl -p CanReload show $service 2>/dev/null)" = "CanReload=no" ] && "$1" = "reload"; then
+                   _use_systemctl=0
+            fi
        esac
     else
        export _SYSTEMCTL_SKIP_REDIRECT="true"