[Groonga-commit] droonga/droonga-engine at 16e9aaf [master] Handle error while downloading of service script

Back to archive index

YUKI Hiroshi null+****@clear*****
Mon Sep 29 14:59:23 JST 2014


YUKI Hiroshi	2014-09-29 14:59:23 +0900 (Mon, 29 Sep 2014)

  New Revision: 16e9aaf2e6236c6202bd62613563455ba8c30b1e
  https://github.com/droonga/droonga-engine/commit/16e9aaf2e6236c6202bd62613563455ba8c30b1e

  Message:
    Handle error while downloading of service script

  Modified files:
    install/centos/functions.sh
    install/debian/functions.sh

  Modified: install/centos/functions.sh (+5 -0)
===================================================================
--- install/centos/functions.sh    2014-09-29 14:56:47 +0900 (2c39532)
+++ install/centos/functions.sh    2014-09-29 14:59:23 +0900 (b198969)
@@ -25,6 +25,11 @@ register_service() {
   chown -R $USER:$GROUP $pid_dir
 
   curl -o /etc/rc.d/init.d/$NAME $(download_url "install/centos/$NAME")
+  if [ $? -ne 0 ]; then
+    echo "ERROR: Failed to download service script!"
+    exit 1
+  fi
+
   chmod +x /etc/rc.d/init.d/$NAME
   /sbin/chkconfig --add $NAME
 }

  Modified: install/debian/functions.sh (+5 -0)
===================================================================
--- install/debian/functions.sh    2014-09-29 14:56:47 +0900 (ba1b36c)
+++ install/debian/functions.sh    2014-09-29 14:59:23 +0900 (0c65ba7)
@@ -23,6 +23,11 @@ register_service() {
   chown -R $USER:$GROUP $pid_dir
 
   curl -o /etc/init.d/$NAME $(download_url "install/debian/$NAME")
+  if [ $? -ne 0 ]; then
+    echo "ERROR: Failed to download service script!"
+    exit 1
+  fi
+
   chmod +x /etc/init.d/$NAME
   update-rc.d $NAME defaults
 }
-------------- next part --------------
HTML����������������������������...
Descargar 



More information about the Groonga-commit mailing list
Back to archive index