Permalink
Browse files

Changed watchdog->daemonwatch

  • Loading branch information...
1 parent e5c78f9 commit a3819894e3015c252838f29568993328760f3a4e @sebastien committed Mar 20, 2012
@@ -0,0 +1,21 @@
+# upstart - Daemonwatch Configuration File
+# ========================================
+# updated: 2011-02-28
+
+description "Daemonwatch - service monitoring daemon"
+author "Sebastien Pierre <sebastien@ffctn.com>"
+
+start on (net-device-up and local-filesystems)
+stop on runlevel [016]
+
+respawn
+console output
+
+script
+ # NOTE: Change this to wherever the daemonwatch is installed
+ DAEMONWATCH_HOME=/opt/services/daemonwatch
+ cd $DAEMONWATCH_HOME
+ # NOTE: Change this to wherever your custom daemonwatch script is installed
+ python $DAEMONWATCH_HOME/daemonwatch.py
+end script
+# EOF
@@ -1,22 +0,0 @@
-# upstart - Watchdog Configuration File
-# =====================================
-# updated: 2011-02-28
-
-description "Watchdog - service monitoring daemon"
-author "Sebastien Pierre <sebastien@ffctn.com>"
-
-start on (net-device-up and local-filesystems)
-stop on runlevel [016]
-
-respawn
-
-script
- # NOTE: Change this to wherever the watchdog is installed
- WATCHDOG_HOME=/opt/services/watchdog
- cd $WATCHDOG_HOME
- # NOTE: Change this to wherever your custom watchdog script is installed
- python watchdog.py
-end script
-
-console output
-# EOF
@@ -1,4 +1,4 @@
-from watchdog import *
+from daemonwatch import *
__doc__ = """How to ensure that a given (HTTP) service stays up and running."""
Monitor(
Service(
@@ -18,7 +18,7 @@
# We kill the 'myservice-start.py' script if it exists
# and (re)start it, so that the 'http://localhost:8000' will
# become available
- # NOTE: Restart will make the process a child of the watchdog, so
+ # NOTE: Restart will make the process a child of the daemonwatch, so
# you might prefer to use something like upstart
Restart("myservice-start.py")
]
@@ -1,11 +1,11 @@
#!/usr/bin/env python
-from watchdog import *
+from daemonwatch import *
Monitor(
Service(
name = "google-search-latency",
monitor = (
HTTP(
- GET="http://www.google.ca/search?q=watchdog",
+ GET="http://www.google.ca/search?q=daemonwatch",
freq=Time.s(1),
timeout=Time.ms(80),
fail=[
@@ -1,4 +1,4 @@
-from watchdog import *
+from daemonwatch import *
Monitor (
Service(
name = "system-health",
@@ -18,7 +18,7 @@
SystemHealth(
cpu=0.90, disk=0.90, mem=0.90,
freq=Time.s(60),
- fail=[Log(path="watchdog-system-failures.log")]
+ fail=[Log(path="daemonwatch-system-failures.log")]
),
)
)
View
@@ -1,5 +1,5 @@
-# Watchdog makefile
-# ---------------
+# Daemonwatch makefile
+# --------------------
#
# Revision 1.5.1 (24-Mar-2006)
#
@@ -24,9 +24,8 @@
# Project variables___________________________________________________________
#
# Project name. Do not put spaces.
-PROJECT = watchdog
-PROJECT_VERSION = 0.9.0
-PROJECT_STATUS = BETA
+PROJECT = daemonwatch
+PROJECT_VERSION = $(shell grep __version__ Sources/*.py | cut -d'"' -f2)
DOCUMENTATION = Documentation
SOURCES = Sources
@@ -39,10 +38,10 @@ DISTROCONTENT = $(DOCUMENTATION) $(SOURCES) $(TESTS) $(RESOURCES) \
# Project files_______________________________________________________________
-PACKAGE = watchdog
+PACKAGE = daemonwatch
MAIN =
MODULES = \
- watchdog \
+ daemonwatch \
TEST_MAIN = $(TESTS)/$(PROJECT)Test.py
SOURCE_FILES = $(shell find $(SOURCES) -name "*.py")
@@ -90,7 +89,7 @@ all: prepare clean check test doc dist
@echo "Making everything for $(PROJECT)"
info:
- @echo "$(PROJECT)-$(PROJECT_VERSION) ($(PROJECT_STATUS))"
+ @echo "$(PROJECT)-$(PROJECT_VERSION)"
@echo Source file lines:
@wc -l $(SOURCE_FILES)
View
@@ -1,5 +1,5 @@
-Watchdog - Server monitoring and data-collection Daemon
-=======================================================
+Daemonwatch - Server monitoring and data-collection daemon
+==========================================================
We want...
----------
@@ -29,9 +29,9 @@ Use Cases
Installation
------------
Sorry, no 'setup.py' for now. Just have a look in the 'Examples' and 'Test'
-directories for more info. Just be sure that 'Source/watchdog.py' is
+directories for more info. Just be sure that 'Source/daemonwatch.py' is
in 'sys.path'.
More?
-----
-Read the `presentation on Watchdog <http://ur1.ca/45ku5>`_
+Read the `presentation on Daemonwatch <http://ur1.ca/45ku5>`_
View
@@ -0,0 +1,3 @@
+#!/usr/bin/python
+import sys, daemonwatch
+daemonwatch.command(sys.argv[1:])
Oops, something went wrong.

0 comments on commit a381989

Please sign in to comment.