diff options
author | Ken Raffenetti <raffenet@mcs.anl.gov> | 2006-09-25 20:13:47 +0000 |
---|---|---|
committer | Ken Raffenetti <raffenet@mcs.anl.gov> | 2006-09-25 20:13:47 +0000 |
commit | 1cb2081eb7ece5b3f3ab335599f22095f7250f99 (patch) | |
tree | 9eb85ac930863b82c181fa4c0f9f24d33ed7fe25 /src/lib | |
parent | d7c171bd05caa5ad988eeb876ed402157a7ff8e6 (diff) | |
download | bcfg2-1cb2081eb7ece5b3f3ab335599f22095f7250f99.tar.gz bcfg2-1cb2081eb7ece5b3f3ab335599f22095f7250f99.tar.bz2 bcfg2-1cb2081eb7ece5b3f3ab335599f22095f7250f99.zip |
more template fixes
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@2312 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/Server/Plugins/Hostbase.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/Server/Plugins/Hostbase.py b/src/lib/Server/Plugins/Hostbase.py index 9d9a92f8e..589d8920b 100644 --- a/src/lib/Server/Plugins/Hostbase.py +++ b/src/lib/Server/Plugins/Hostbase.py @@ -47,7 +47,7 @@ class Hostbase(Plugin): Plugin.__init__(self, core, datastore) sys.path.append(self.data) os.environ['DJANGO_SETTINGS_MODULE'] = 'settings' - from django.template import loader, Context + from django.template import loader ## try: ## DataNexus.__init__(self, datastore + '/Hostbase/data', ## files, self.core.fam) @@ -71,7 +71,7 @@ class Hostbase(Plugin): self.rebuildState(None) except: raise PluginInitError - + def FetchFile(self, entry, metadata): '''Return prebuilt file data''' fname = entry.get('name').split('/')[-1] @@ -262,6 +262,7 @@ class Hostbase(Plugin): '''Pre-build dhcpd.conf and stash in the filedata table''' from django.db import connection + from django.template import Context # fetches all the hosts with DHCP == True cursor = connection.cursor() |