summaryrefslogtreecommitdiffstats
path: root/generators
diff options
context:
space:
mode:
authorNarayan Desai <desai@mcs.anl.gov>2004-06-09 18:36:20 +0000
committerNarayan Desai <desai@mcs.anl.gov>2004-06-09 18:36:20 +0000
commit90835672def71ea5200b2cb6f358ceb06f76492d (patch)
treeeb22f1a8f4f3ca5975c2215dabfe09f25b2e9d84 /generators
parenteaa0d649a5d86c432d12f4cf1d42d35b02647773 (diff)
downloadbcfg2-90835672def71ea5200b2cb6f358ceb06f76492d.tar.gz
bcfg2-90835672def71ea5200b2cb6f358ceb06f76492d.tar.bz2
bcfg2-90835672def71ea5200b2cb6f358ceb06f76492d.zip
update to new API
2004/06/08 09:52:06-05:00 anl.gov!desai update to new API (Logical change 1.21) git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@90 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'generators')
-rw-r--r--generators/fstab.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/generators/fstab.py b/generators/fstab.py
index 4fd026836..bc5535b4d 100644
--- a/generators/fstab.py
+++ b/generators/fstab.py
@@ -10,15 +10,15 @@ class fstab(Generator):
__name__ = 'fstab'
__version__ = '$Id$'
__author__ = 'bcfg-dev@mcs.anl.gov'
- __build__ = {'/etc/fstab':'build_fstab'}
mayor = compile("\$MAYOR")
def __setup__(self):
self.repo = DirectoryBacked(self.data, self.core.fam)
+ self.__provides__ = {'ConfigFile':{'/etc/fstab':self.build_fstab}}
- def build_fstab(self,name,client):
- node = client.split('.')[0]
+ def build_fstab(self,name,metadata):
+ node = metadata.hostname.split('.')[0]
if 'ccn' in node:
nodeclass = 'compute'
mayor = 'cct%sm.mcs.anl.gov'%((int(node[3:]) / 32) + 1)