diff options
author | Sol Jerome <solj@ices.utexas.edu> | 2009-09-07 01:54:44 +0000 |
---|---|---|
committer | Sol Jerome <solj@ices.utexas.edu> | 2009-09-07 01:54:44 +0000 |
commit | f431b4b08bf2e0b28225bfdf84f62aa2a8aa9bbb (patch) | |
tree | d9375a98a21eb3991e9039fba5fc6cd3eda3de9a /src/lib/Client/Tools | |
parent | 869f3f2cc0fabdb46e2e0863d830b7d8525c13ee (diff) | |
download | bcfg2-f431b4b08bf2e0b28225bfdf84f62aa2a8aa9bbb.tar.gz bcfg2-f431b4b08bf2e0b28225bfdf84f62aa2a8aa9bbb.tar.bz2 bcfg2-f431b4b08bf2e0b28225bfdf84f62aa2a8aa9bbb.zip |
POSIX: Add support for unified Path entries
This commit adds support for a new Path entry which unifies all the
various POSIX entry types. A new plugin is included which will allow you
to transform new Path entries back into their old format (for
compatibility with old clients).
Signed-off-by: Sol Jerome <solj@ices.utexas.edu>
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@5414 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Client/Tools')
-rw-r--r-- | src/lib/Client/Tools/POSIX.py | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/lib/Client/Tools/POSIX.py b/src/lib/Client/Tools/POSIX.py index bfbe79066..bc9626e88 100644 --- a/src/lib/Client/Tools/POSIX.py +++ b/src/lib/Client/Tools/POSIX.py @@ -79,11 +79,11 @@ def isString(strng): class POSIX(Bcfg2.Client.Tools.Tool): '''POSIX File support code''' name = 'POSIX' - __handles__ = [('ConfigFile', None), ('Directory', None), - ('Path', 'ConfigFile'), ('Path', 'Device'), - ('Path', 'Directory'), ('Path', 'Perms'), - ('Path', 'SymLink'), ('Permissions', None), - ('SymLink', None)] + __handles__ = [('ConfigFile', None), ('ConfigFile', 'Compat'), + ('Directory', None), ('Path', 'ConfigFile'), + ('Path', 'Device'), ('Path', 'Directory'), + ('Path', 'Perms'), ('Path', 'SymLink'), + ('Permissions', None), ('SymLink', None)] __req__ = {'ConfigFile': ['name', 'owner', 'group', 'perms'], 'Directory': ['name', 'owner', 'group', 'perms'], 'Path': ['name', 'type'], @@ -149,6 +149,12 @@ class POSIX(Bcfg2.Client.Tools.Tool): except OSError: return False + def VerifyDevice(self, entry, _): + return False + + def InstallDevice(self, entry): + return False + def VerifyDirectory(self, entry, modlist): '''Verify Directory Entry''' while len(entry.get('perms', '')) < 4: |