diff options
author | Sol Jerome <sol.jerome@gmail.com> | 2011-04-12 10:18:55 -0500 |
---|---|---|
committer | Sol Jerome <sol.jerome@gmail.com> | 2011-04-12 10:18:55 -0500 |
commit | 545dda76d34a06ae25efa2eb3d0c8c0bd70127d0 (patch) | |
tree | 7e11617f4d81465c8a75ee343e550bb424ac3730 /src/lib/Client/Tools/SMF.py | |
parent | 33d4e0178b26dc4756a4b933a9f966379ce99453 (diff) | |
download | bcfg2-545dda76d34a06ae25efa2eb3d0c8c0bd70127d0.tar.gz bcfg2-545dda76d34a06ae25efa2eb3d0c8c0bd70127d0.tar.bz2 bcfg2-545dda76d34a06ae25efa2eb3d0c8c0bd70127d0.zip |
Tools: Skip Installation for mode='manual' services (#965)
This allows for verification of specified services, but skips
installation completely when mode is set to manual. This means that
incorrect services will still show up in reports, but they won't be
modified in an automated way.
Signed-off-by: Sol Jerome <sol.jerome@gmail.com>
Diffstat (limited to 'src/lib/Client/Tools/SMF.py')
-rw-r--r-- | src/lib/Client/Tools/SMF.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lib/Client/Tools/SMF.py b/src/lib/Client/Tools/SMF.py index 96c7d9d28..0403ff62e 100644 --- a/src/lib/Client/Tools/SMF.py +++ b/src/lib/Client/Tools/SMF.py @@ -74,6 +74,11 @@ class SMF(Bcfg2.Client.Tools.SvcTool): def InstallService(self, entry): """Install SMF Service entry.""" + # don't take any actions for mode='manual' + if entry.get('mode', 'default') == 'manual': + self.logger.info("Service %s mode set to manual. Skipping " + "installation." % (entry.get('name'))) + return True self.logger.info("Installing Service %s" % (entry.get('name'))) if entry.get('status') == 'off': if entry.get("FMRI").startswith('lrc'): |