]> git.pld-linux.org Git - packages/asterisk.git/blobdiff - asterisk.init
- http://soft-switch.org/downloads/spandsp/spandsp-0.0.2pre25/asterisk-1.2.x/
[packages/asterisk.git] / asterisk.init
index d50196eb3cdfff71df6431fb0c9ab8acb5dd4a0f..d14d8a9677b6d836453ecbc4dfaff5b01be4de22 100644 (file)
@@ -10,7 +10,7 @@
 #              developing custom telephony applications for delivering dynamic \
 #              content over a telephone similarly to how one can deliver dynamic \
 #              content through a web browser using CGI and a web server.
-#              
+#
 # pidfile:     /var/run/asterisk.pid
 # config:      /etc/asterisk/asterisk.conf
 
@@ -66,18 +66,19 @@ case "$1" in
        $0 start
        exit $?
        ;;
-#  reload)
-       # Should be some better way...
-#      $0 restart
-#      if [ -f /var/lock/subsys/ ]; then
-#              msg_reloading Asterisk
-#              busy
-#              ok
-#      else
-#              msg_not_running Asterisk
-#              exit 1
-#      fi
-#      ;;
+  reload)
+       if [ -f /var/lock/subsys/asterisk ]; then
+               msg_reloading Asterisk
+               busy
+               asterisk -rx reload > /dev/null 2>&1
+               RETVAL=$?
+               [ $RETVAL -eq 0 ] && touch /var/lock/subsys/asterisk
+               ok
+       else
+               msg_not_running Asterisk
+               exit 1
+       fi
+       ;;
   status)
        status asterisk
        exit $?
This page took 0.05702 seconds and 4 git commands to generate.