s4-dns: Update template variables, change BIND98 --> BIND9_8
authorAmitay Isaacs <amitay@gmail.com>
Mon, 20 Oct 2014 05:40:05 +0000 (16:40 +1100)
committerAmitay Isaacs <amitay@samba.org>
Sat, 25 Oct 2014 01:21:04 +0000 (03:21 +0200)
This makes it easier to add suport for BIND 9.10.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Matthieu Patou <mat@matws.net>
python/samba/provision/sambadns.py
source4/setup/named.conf.dlz

index 29224c8cf6941643190bcc10b8c6db72e2d3b9e6..1ab8f4e30359b190d39258bb61ddc75886f726d6 100644 (file)
@@ -919,12 +919,12 @@ def create_named_conf(paths, realm, dnsdomain, dns_backend, logger):
                                      stdout=subprocess.PIPE,
                                      stderr=subprocess.STDOUT,
                                      cwd='.').communicate()[0]
-        bind98 = '#'
-        bind99 = '#'
+        bind9_8 = '#'
+        bind9_9 = '#'
         if bind_info.upper().find('BIND 9.8') != -1:
-            bind98 = ''
+            bind9_8 = ''
         elif bind_info.upper().find('BIND 9.9') != -1:
-            bind99 = ''
+            bind9_9 = ''
         elif bind_info.upper().find('BIND 9.7') != -1:
             raise ProvisioningError("DLZ option incompatible with BIND 9.7.")
         else:
@@ -932,8 +932,8 @@ def create_named_conf(paths, realm, dnsdomain, dns_backend, logger):
         setup_file(setup_path("named.conf.dlz"), paths.namedconf, {
                     "NAMED_CONF": paths.namedconf,
                     "MODULESDIR" : samba.param.modules_dir(),
-                    "BIND98" : bind98,
-                    "BIND99" : bind99
+                    "BIND9_8" : bind9_8,
+                    "BIND9_9" : bind9_9
                     })
 
 
index d91a020f911596cc066ed3d8d3c6cfba243b9310..2b884e9718b7788e3d6bc25e74a9101dd9382b93 100644 (file)
 # Uncomment only single database line, depending on your BIND version
 #
 dlz "AD DNS Zone" {
-    # For BIND 9.8.0
-    ${BIND98} database "dlopen ${MODULESDIR}/bind9/dlz_bind9.so";
+    # For BIND 9.8.x
+    ${BIND9_8} database "dlopen ${MODULESDIR}/bind9/dlz_bind9.so";
 
-    # For BIND 9.9.0
-    ${BIND99} database "dlopen ${MODULESDIR}/bind9/dlz_bind9_9.so";
+    # For BIND 9.9.x
+    ${BIND9_9} database "dlopen ${MODULESDIR}/bind9/dlz_bind9_9.so";
 };