Update IPADDR references

This commit is contained in:
bergware
2016-05-12 08:49:48 +02:00
parent d147bd1455
commit 4a43eef8d8
4 changed files with 4 additions and 4 deletions
@@ -74,7 +74,7 @@ img.stopped{opacity:0.3;}
$info = $DockerTemplates->getAllInfo();
$contextMenus = [];
$IP = $var["IPADDR"];
$IP = $eth0["IPADDR:0"];
foreach ($all_containers as $ct) {
$name = $ct["Name"];
$is_autostart = ($info[$name]['autostart']) ? 'true' : 'false';
@@ -247,7 +247,7 @@ class DockerTemplates {
$WebUI = $this->getTemplateValue($Repository, "WebUI");
if (preg_match("%\[IP\]%", $WebUI)) {
$WebUI = preg_replace("%\[IP\]%", $var["IPADDR"], $WebUI);
$WebUI = preg_replace("%\[IP\]%", $eth0["IPADDR:0"], $WebUI);
}
if (preg_match("%\[PORT:(\d+)\]%", $WebUI, $matches)) {
$ConfigPort = $matches[1];
@@ -131,7 +131,7 @@
$wsport = $lv->domain_get_ws_port($dom);
if ($vncport > 0) {
$vnc = '/plugins/dynamix.vm.manager/vnc.html?autoconnect=true&host='.$var['IPADDR'].'&port='.$wsport;
$vnc = '/plugins/dynamix.vm.manager/vnc.html?autoconnect=true&host='.$eth0['IPADDR:0'].'&port='.$wsport;
$arrResponse['vncurl'] = $vnc;
}
}
+1 -1
View File
@@ -128,7 +128,7 @@ foreach ($allVMs as $name) {
$vnc = '';
if ($vncport > 0) {
$wsport = $lv->domain_get_ws_port($res);
$vnc = '/plugins/dynamix.vm.manager/vnc.html?autoconnect=true&host=' . $var['IPADDR'] . '&port=' . $wsport;
$vnc = '/plugins/dynamix.vm.manager/vnc.html?autoconnect=true&host=' . $eth0['IPADDR:0'] . '&port=' . $wsport;
} else {
$vncport = ($vncport < 0) ? "auto" : "";
}