From: Yan, Zheng Date: Thu, 23 Jul 2015 07:07:45 +0000 (+0800) Subject: init-ceph: check if /lib/lsb/init-functions exists X-Git-Tag: v9.1.0~259^2~24 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=bb1fa7f3993dfcd1243b2a9a0bb432c269df215f;p=ceph.git init-ceph: check if /lib/lsb/init-functions exists On OSX/FreeBSD, /lib/lsb/init-functions does not exist Signed-off-by: Yan, Zheng --- diff --git a/src/init-ceph.in b/src/init-ceph.in index 22f595ad2b51..4255c550a434 100755 --- a/src/init-ceph.in +++ b/src/init-ceph.in @@ -12,7 +12,10 @@ # Description: Enable Ceph distributed file system services. ### END INIT INFO -. /lib/lsb/init-functions +# TODO: on FreeBSD/OSX, use equivalent script file +if [ -e /lib/lsb/init-functions ]; then + . /lib/lsb/init-functions +fi # detect systemd, also check whether the systemd-run binary exists SYSTEMD_RUN=$(which systemd-run 2>/dev/null)