[Groonga-commit] droonga/droonga-engine at 21330d1 [master] Use old startup script instead of systemd for now, for CentOS 7

Back to archive index

YUKI Hiroshi null+****@clear*****
Thu Sep 25 16:38:18 JST 2014


YUKI Hiroshi	2014-09-25 16:38:18 +0900 (Thu, 25 Sep 2014)

  New Revision: 21330d164f308d8e072f2a37b1a439c3df926310
  https://github.com/droonga/droonga-engine/commit/21330d164f308d8e072f2a37b1a439c3df926310

  Message:
    Use old startup script instead of systemd for now, for CentOS 7

  Modified files:
    install/centos/droonga-engine
    lib/droonga/service_installation.rb

  Modified: install/centos/droonga-engine (+3 -0)
===================================================================
--- install/centos/droonga-engine    2014-09-25 12:53:27 +0900 (d6520a7)
+++ install/centos/droonga-engine    2014-09-25 16:38:18 +0900 (bbc35df)
@@ -5,6 +5,9 @@
 #	<Droonga engine is a core component in Droonga system>
 # chkconfig: 2345 20 80
 
+# TODO: we have to migrate to systemd based management in near future...
+export SYSTEMCTL_SKIP_REDIRECT=yes
+
 # Source function library.
 . /etc/init.d/functions
 

  Modified: lib/droonga/service_installation.rb (+7 -2)
===================================================================
--- lib/droonga/service_installation.rb    2014-09-25 12:53:27 +0900 (80f9e2d)
+++ lib/droonga/service_installation.rb    2014-09-25 16:38:18 +0900 (8addc61)
@@ -75,12 +75,14 @@ module Droonga
     def installed_as_service?
       return false unless user_exist?
     
+      #TODO: we should support systemd also...
       succeeded = system("service", "droonga-engine", "status",
                          :out => "/dev/null",
                          :err => "/dev/null")
       return true if succeeded
     
-      result = `env SYSTEMCTL_SKIP_REDIRECT=yes service droonga-engine status`
+      #TODO: we should support systemd also...
+      result = `service droonga-engine status`
       result.include?("running") or \
         result.include?("droonga-engine is stopped") or \
         result.include?("droonga-engine dead")
@@ -95,12 +97,14 @@ module Droonga
 
     def running?(pid_file_path=nil)
       raise NotInstalledAsService.new unless installed_as_service?
-      result = `env SYSTEMCTL_SKIP_REDIRECT=yes service droonga-engine status`
+      #TODO: we should support systemd also...
+      result = `service droonga-engine status`
       result.include?("running")
     end
 
     def start
       raise NotInstalledAsService.new unless installed_as_service?
+      #TODO: we should support systemd also...
       system("service", "droonga-engine", "start",
              :out => "/dev/null",
              :err => "/dev/null")
@@ -108,6 +112,7 @@ module Droonga
 
     def stop
       raise NotInstalledAsService.new unless installed_as_service?
+      #TODO: we should support systemd also...
       system("service", "droonga-engine", "stop",
              :out => "/dev/null",
              :err => "/dev/null")
-------------- next part --------------
HTML����������������������������...
Download 



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