summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2017-09-13 15:00:57 +0000
committerTed Trask <ttrask01@yahoo.com>2017-09-13 15:00:57 +0000
commit4aad1b4b48c4c77462176f4c896fe5688d6f9762 (patch)
tree349ae398f358fe16c0ed42094dc3c3c59ad7e623
parent3ca2a491c942ca63d768008299b240424ea1efed (diff)
downloadacf-provisioning-4aad1b4b48c4c77462176f4c896fe5688d6f9762.tar.bz2
acf-provisioning-4aad1b4b48c4c77462176f4c896fe5688d6f9762.tar.xz
Override DHCP when sntpserver or tz defined in polycom template
-rw-r--r--config/templates/polycom-template.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/config/templates/polycom-template.lua b/config/templates/polycom-template.lua
index bb736db..892d8e6 100644
--- a/config/templates/polycom-template.lua
+++ b/config/templates/polycom-template.lua
@@ -136,6 +136,7 @@ end
-- Examples: 'GMT0' 'EST5EDT,M3.2.0,M11.1.0' '<GMT+5>5'
if values.device.sntpserver then
xml_attr({ 'tcpIpApp.sntp.address' }, values.device.sntpserver)
+ xml_attr({ 'tcpIpApp.sntp.address.overrideDHCP' }, true)
end
-- Parse time zone variable
@@ -143,6 +144,7 @@ posixtz = require('posixtz')
local tz = posixtz.parse(values.device.timezone)
if tz then
+ xml_attr({ 'tcpIpApp.sntp.gmtOffset.overrideDHCP' }, true)
-- convert POSIX sign (W of GMT is '+') to Polycom (E of GMT is '+')
xml_attr({'tcpIpApp.sntp.gmtOffset'}, -1 * tz.offset.total)