summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorSeth Mos <seth.mos@xs4all.nl>2007-05-08 14:47:07 +0000
committerSeth Mos <seth.mos@xs4all.nl>2007-05-08 14:47:07 +0000
commitad1719997b25299696078eb7c2d8329d8bc8f84d (patch)
treee2c9b54b50040dbdb787f3b1e6a9ceb43d35379c /etc
parent232d6540f9ceaf0c67b2ec500d15223eb63fc7f1 (diff)
downloadpfsense-ad1719997b25299696078eb7c2d8329d8bc8f84d.zip
pfsense-ad1719997b25299696078eb7c2d8329d8bc8f84d.tar.gz
Add NTP server field to dhcp config.
From: Alexander Schaber
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/services.inc3
-rw-r--r--etc/inc/xmlparse.inc4
2 files changed, 5 insertions, 2 deletions
diff --git a/etc/inc/services.inc b/etc/inc/services.inc
index 341f00f..a95e22a 100644
--- a/etc/inc/services.inc
+++ b/etc/inc/services.inc
@@ -264,6 +264,9 @@ EOD;
$dhcpdconf .= " option netbios-node-type 8;\n";
}
+ if (is_array($dhcpifconf['ntpserver']) && $dhcpifconf['ntpserver'][0])
+ $dhcpdconf .= " option ntp-servers " . join(",", $dhcpifconf['ntpserver']) . ";\n";
+
if(isset($dhcpifconf['netboot'])) {
if (($dhcpifconf['next-server'] <> "") && ($dhcpifconf['filename'] <> "")) {
$dhcpdconf .= " next-server {$dhcpifconf['next-server']};\n";
diff --git a/etc/inc/xmlparse.inc b/etc/inc/xmlparse.inc
index b6bb16a..9abda50 100644
--- a/etc/inc/xmlparse.inc
+++ b/etc/inc/xmlparse.inc
@@ -36,7 +36,7 @@ function listtags() {
"earlyshellcmd encryption-algorithm-option field fieldname hash-algorithm-option " .
"hosts group interface_array item key lbpool menu mobilekey mount onetoone option package passthrumac priv proxyarpnet " .
"queue pages pipe route row rule schedule service servernat servers earlyshellcmd shellcmd staticmap subqueue " .
- "timerange tunnel user vip virtual_server vlan winsserver wolentry widget depends_on_package");
+ "timerange tunnel user vip virtual_server vlan winsserver ntpserver wolentry widget depends_on_package");
return $ret;
}
@@ -259,4 +259,4 @@ function dump_xml_config_raw($arr, $rootobj) {
return $xmlconfig;
}
-?> \ No newline at end of file
+?>
OpenPOWER on IntegriCloud