summaryrefslogtreecommitdiffstats
path: root/src/lib/Client
diff options
context:
space:
mode:
authorJoe Digilio <jdigilio@imca.aps.anl.gov>2011-03-24 14:56:06 -0500
committerJoe Digilio <jdigilio@imca.aps.anl.gov>2011-03-25 11:47:58 -0500
commita39e7b33dc921cf145bd2b3ce81a6b35a062f720 (patch)
tree1f757f96d04216462e6357acbf8d346c11c81b58 /src/lib/Client
parent1d9cae6d4761aec978e8cf78ebdebd32571b531a (diff)
downloadbcfg2-a39e7b33dc921cf145bd2b3ce81a6b35a062f720.tar.gz
bcfg2-a39e7b33dc921cf145bd2b3ce81a6b35a062f720.tar.bz2
bcfg2-a39e7b33dc921cf145bd2b3ce81a6b35a062f720.zip
add ability to ignore a Service
Diffstat (limited to 'src/lib/Client')
-rw-r--r--src/lib/Client/Tools/DebInit.py4
-rw-r--r--src/lib/Client/Tools/Upstart.py4
2 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/Client/Tools/DebInit.py b/src/lib/Client/Tools/DebInit.py
index 119036b32..fc67a73e4 100644
--- a/src/lib/Client/Tools/DebInit.py
+++ b/src/lib/Client/Tools/DebInit.py
@@ -21,6 +21,10 @@ class DebInit(Bcfg2.Client.Tools.SvcTool):
# implement entry (Verify|Install) ops
def VerifyService(self, entry, _):
"""Verify Service status for entry."""
+
+ if entry.get('status') == 'ignore':
+ return True
+
rawfiles = glob.glob("/etc/rc*.d/[SK]*%s" % (entry.get('name')))
files = []
diff --git a/src/lib/Client/Tools/Upstart.py b/src/lib/Client/Tools/Upstart.py
index b75b0927e..7a94a07f3 100644
--- a/src/lib/Client/Tools/Upstart.py
+++ b/src/lib/Client/Tools/Upstart.py
@@ -29,6 +29,10 @@ class Upstart(Bcfg2.Client.Tools.SvcTool):
/etc/init/servicename.conf. All we need to do is make sure
the service is running when it should be.
"""
+
+ if entry.get('status') == 'ignore':
+ return True
+
if entry.get('parameters'):
params = entry.get('parameters')
else: