Signed-off-by: Guido Trotter <[email protected]>
---
 Makefile.am             |    1 +
 hooks/watcher/check-nld |   34 ++++++++++++++++++++++++++++++++++
 2 files changed, 35 insertions(+), 0 deletions(-)
 create mode 100755 hooks/watcher/check-nld

diff --git a/Makefile.am b/Makefile.am
index c8890fa..474c904 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -57,6 +57,7 @@ EXTRA_DIST = \
        scripts/iptables_setup.in \
        scripts/routing_setup.in \
        scripts/common.sh.in \
+       hooks/watcher/check-nld \
        $(docrst) \
        $(RUN_IN_TEMPDIR) \
        $(TEST_FILES) \
diff --git a/hooks/watcher/check-nld b/hooks/watcher/check-nld
new file mode 100755
index 0000000..084bad8
--- /dev/null
+++ b/hooks/watcher/check-nld
@@ -0,0 +1,34 @@
+#!/usr/bin/python
+#
+
+# Copyright (C) 2010 Google Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301, USA.
+
+
+from ganeti_nbma import constants
+
+from ganeti import utils
+
+def main():
+  """Main function.
+
+  """
+  utils.EnsureDaemon(constants.NLD)
+
+if __name__ == '__main__':
+  main()
+
-- 
1.6.6.1

Reply via email to