diff options
author | Narayan Desai <desai@mcs.anl.gov> | 2005-09-30 19:26:49 +0000 |
---|---|---|
committer | Narayan Desai <desai@mcs.anl.gov> | 2005-09-30 19:26:49 +0000 |
commit | 67e1f5c6b05e5c720cdd15424e33860885b6cd40 (patch) | |
tree | a060cf7fd40ed4abe64fe31dbe3b2baeacd5d77f /src/lib/Client/Redhat.py | |
parent | c7efe2d0a87724ce3d60e416d19bc29cb0b8783d (diff) | |
download | bcfg2-67e1f5c6b05e5c720cdd15424e33860885b6cd40.tar.gz bcfg2-67e1f5c6b05e5c720cdd15424e33860885b6cd40.tar.bz2 bcfg2-67e1f5c6b05e5c720cdd15424e33860885b6cd40.zip |
add extra service support
(Logical change 1.329)
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1344 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Client/Redhat.py')
-rw-r--r-- | src/lib/Client/Redhat.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/lib/Client/Redhat.py b/src/lib/Client/Redhat.py index 6f03f170b..ee952c0fa 100644 --- a/src/lib/Client/Redhat.py +++ b/src/lib/Client/Redhat.py @@ -131,3 +131,12 @@ class Redhat(Toolset): else: self.CondPrint('verbose', "Need to remove services: %s" % self.extra_services) + def Inventory(self): + '''Do standard inventory plus debian extra service check''' + Toolset.Inventory(self) + allsrv = [line.split()[0] for line in popen("chkconfig --list|grep :on").readlines()] + self.CondPrint('debug', "Found active services: %s" % allsrv) + csrv = self.cfg.findall(".//Service") + [allsrv.remove(svc.get('name')) for svc in csrv if + svc.get('status') == 'on' and svc.get('name') in allsrv] + self.extra_services = allsrv |