diff options
author | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2012-09-11 10:32:30 -0400 |
---|---|---|
committer | Chris St. Pierre <chris.a.st.pierre@gmail.com> | 2012-09-11 10:32:30 -0400 |
commit | 71c679e1a0105490bd5845a15de5e8f1a32e2166 (patch) | |
tree | c528e62098b599d7ae74ea53908a045ccf2ffb63 /src/lib/Bcfg2/Server/Plugins/Cfg/CfgExternalCommandVerifier.py | |
parent | b682d9e3c11f94a9a9dc254a6d53e44f953a74bf (diff) | |
download | bcfg2-71c679e1a0105490bd5845a15de5e8f1a32e2166.tar.gz bcfg2-71c679e1a0105490bd5845a15de5e8f1a32e2166.tar.bz2 bcfg2-71c679e1a0105490bd5845a15de5e8f1a32e2166.zip |
Cfg: documented all Cfg modules, added development docs
Diffstat (limited to 'src/lib/Bcfg2/Server/Plugins/Cfg/CfgExternalCommandVerifier.py')
-rw-r--r-- | src/lib/Bcfg2/Server/Plugins/Cfg/CfgExternalCommandVerifier.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/Bcfg2/Server/Plugins/Cfg/CfgExternalCommandVerifier.py b/src/lib/Bcfg2/Server/Plugins/Cfg/CfgExternalCommandVerifier.py index f0c1109ec..87e11ab6d 100644 --- a/src/lib/Bcfg2/Server/Plugins/Cfg/CfgExternalCommandVerifier.py +++ b/src/lib/Bcfg2/Server/Plugins/Cfg/CfgExternalCommandVerifier.py @@ -1,3 +1,5 @@ +""" Invoke an external command to verify file contents """ + import os import shlex import logging @@ -8,6 +10,10 @@ from Bcfg2.Server.Plugins.Cfg import CfgVerifier, CfgVerificationError logger = logging.getLogger(__name__) class CfgExternalCommandVerifier(CfgVerifier): + """ Invoke an external script to verify + :ref:`server-plugins-generators-cfg` file contents """ + + #: Handle :file:`:test` files __basenames__ = [':test'] def verify_entry(self, entry, metadata, data): @@ -16,6 +22,7 @@ class CfgExternalCommandVerifier(CfgVerifier): rv = proc.wait() if rv != 0: raise CfgVerificationError(err) + verify_entry.__doc__ = CfgVerifier.verify_entry.__doc__ def handle_event(self, event): if event.code2str() == 'deleted': @@ -30,4 +37,5 @@ class CfgExternalCommandVerifier(CfgVerifier): logger.error(msg) raise Bcfg2.Server.Plugin.PluginExecutionError(msg) self.cmd.append(self.name) + handle_event.__doc__ = CfgVerifier.handle_event.__doc__ |