mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
dns/dyndns: remove the remote notification support
Different fix than @adschellevis, upon closer inspection this seems to make more sense to ditch it. No plugins use the remote notification support, so we can remove / replace it for 18.1.
This commit is contained in:
+1
-1
@@ -1,6 +1,6 @@
|
||||
PLUGIN_NAME= dyndns
|
||||
PLUGIN_VERSION= 1.1
|
||||
PLUGIN_REVISION= 1
|
||||
PLUGIN_REVISION= 2
|
||||
PLUGIN_COMMENT= Dynamic DNS Support
|
||||
PLUGIN_MAINTAINER= franco@opnsense.org
|
||||
|
||||
|
||||
@@ -1119,15 +1119,11 @@ class updatedns {
|
||||
break;
|
||||
}
|
||||
|
||||
if($successful_update == true) {
|
||||
if ($successful_update == true) {
|
||||
/* Write WAN IP to cache file */
|
||||
$wan_ip = $this->_checkIP();
|
||||
$allinterfaces = legacy_config_get_interfaces();
|
||||
$friendlyintf = convert_real_interface_to_friendly_interface_name($this->_if);
|
||||
$intfdescr = $allinterfaces[$friendlyintf]['descr'];
|
||||
if ($this->_useIPv6 == false && $wan_ip > 0) {
|
||||
$currentTime = time();
|
||||
notify_all_remote(sprintf(gettext("Dynamic DNS updated IP Address on %s (%s) to %s"), $intfdescr, $this->_if, $wan_ip));
|
||||
log_error("Dynamic DNS: updating cache file {$this->_cacheFile}: {$wan_ip}");
|
||||
@file_put_contents($this->_cacheFile, "{$wan_ip}|{$currentTime}");
|
||||
} else {
|
||||
@@ -1135,7 +1131,6 @@ class updatedns {
|
||||
}
|
||||
if ($this->_useIPv6 == true && $wan_ip > 0) {
|
||||
$currentTime = time();
|
||||
notify_all_remote(sprintf(gettext("Dynamic DNS updated IPv6 Address on %s (%s) to %s"), $intfdescr, $this->_if, $wan_ip));
|
||||
log_error("Dynamic DNS: updating cache file {$this->_cacheFile_v6}: {$wan_ip}");
|
||||
@file_put_contents($this->_cacheFile_v6, "{$wan_ip}|{$currentTime}");
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user