diff options
author | Sol Jerome <sol.jerome@gmail.com> | 2010-10-18 11:43:37 -0500 |
---|---|---|
committer | Sol Jerome <sol.jerome@gmail.com> | 2010-10-18 11:46:55 -0500 |
commit | 8a70dbabd08308403ad8296979f50c379c707df9 (patch) | |
tree | 37d9604b3c6132b1c71622c8cd7cda319dab76c1 /src/lib/Server/Plugins | |
parent | 16807d819b63384a0f588b4ea881c7b043571875 (diff) | |
download | bcfg2-8a70dbabd08308403ad8296979f50c379c707df9.tar.gz bcfg2-8a70dbabd08308403ad8296979f50c379c707df9.tar.bz2 bcfg2-8a70dbabd08308403ad8296979f50c379c707df9.zip |
POSIX: Remove client-side support for old POSIX types
Signed-off-by: Sol Jerome <sol.jerome@gmail.com>
Diffstat (limited to 'src/lib/Server/Plugins')
-rw-r--r-- | src/lib/Server/Plugins/POSIXCompat.py | 38 | ||||
-rw-r--r-- | src/lib/Server/Plugins/__init__.py | 1 |
2 files changed, 0 insertions, 39 deletions
diff --git a/src/lib/Server/Plugins/POSIXCompat.py b/src/lib/Server/Plugins/POSIXCompat.py deleted file mode 100644 index fc16e4b48..000000000 --- a/src/lib/Server/Plugins/POSIXCompat.py +++ /dev/null @@ -1,38 +0,0 @@ -"""This plugin provides a compatibility layer which turns new-style -POSIX entries into old-style entries. -""" - -__revision__ = '$Revision$' - -import Bcfg2.Server.Plugin - -COMPAT_DICT = {'file': 'ConfigFile', - 'directory': 'Directory', - 'permissions': 'Permissions', - 'symlink': 'SymLink'} - - -class POSIXCompat(Bcfg2.Server.Plugin.Plugin, - Bcfg2.Server.Plugin.GoalValidator): - """POSIXCompat is a goal validator plugin for POSIX entries.""" - name = 'POSIXCompat' - __version__ = '$Id$' - __author__ = 'bcfg-dev@mcs.anl.gov' - - def __init__(self, core, datastore): - Bcfg2.Server.Plugin.Plugin.__init__(self, core, datastore) - Bcfg2.Server.Plugin.GoalValidator.__init__(self) - - def validate_goals(self, metadata, goals): - """Verify that we are generating correct old - Cfg/Directory/Symlink entries. - """ - for goal in goals: - for entry in goal.getchildren(): - if entry.tag == 'Path' and \ - entry.get('type') not in ['nonexistent', 'device']: - # Use new entry 'type' attribute to map old entry tags - oldentry = entry - entry.tag = COMPAT_DICT[entry.get('type')] - del entry.attrib['type'] - goal.replace(oldentry, entry) diff --git a/src/lib/Server/Plugins/__init__.py b/src/lib/Server/Plugins/__init__.py index 758f1219d..c69c37452 100644 --- a/src/lib/Server/Plugins/__init__.py +++ b/src/lib/Server/Plugins/__init__.py @@ -22,7 +22,6 @@ __all__ = [ 'Properties', 'Probes', 'Pkgmgr', - 'POSIXCompat', 'Rules', 'SSHbase', 'Snapshots', |