summaryrefslogtreecommitdiff
path: root/service/OneService.cpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2017-02-13 15:55:38 -0800
committerAdam Ierymenko <adam.ierymenko@gmail.com>2017-02-13 15:55:38 -0800
commitcd7b571da071a4af4afd978b920e1b8372c880a3 (patch)
tree7132df046a0605b844f7140fbf8228d82d60f72d /service/OneService.cpp
parent0052877d2fb9d7779d4612b4ca5b49f46c52b101 (diff)
downloadinfinitytier-cd7b571da071a4af4afd978b920e1b8372c880a3.tar.gz
infinitytier-cd7b571da071a4af4afd978b920e1b8372c880a3.zip
Add a local.conf option to set the port.
Diffstat (limited to 'service/OneService.cpp')
-rw-r--r--service/OneService.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/service/OneService.cpp b/service/OneService.cpp
index d56333c0..aa90798f 100644
--- a/service/OneService.cpp
+++ b/service/OneService.cpp
@@ -987,6 +987,7 @@ public:
_interfacePrefixBlacklist.clear();
json &settings = _localConfig["settings"];
if (settings.is_object()) {
+ _primaryPort = (unsigned int)OSUtils::jsonInt(settings["primaryPort"],(uint64_t)_primaryPort) & 0xffff;
_portMappingEnabled = OSUtils::jsonBool(settings["portMappingEnabled"],true);
const std::string up(OSUtils::jsonString(settings["softwareUpdate"],ZT_SOFTWARE_UPDATE_DEFAULT));