mirror of
https://github.com/apache/cloudstack.git
synced 2025-11-02 20:02:29 +01:00
bug 8960: add management.netaddr.cidr to CPVM and SSVM
This commit is contained in:
parent
7b9b897459
commit
458998c609
@ -112,6 +112,7 @@ import com.cloud.utils.db.GlobalLock;
|
||||
import com.cloud.utils.db.Transaction;
|
||||
import com.cloud.utils.events.SubscriptionMgr;
|
||||
import com.cloud.utils.exception.CloudRuntimeException;
|
||||
import com.cloud.utils.net.NetUtils;
|
||||
import com.cloud.vm.ConsoleProxyVO;
|
||||
import com.cloud.vm.NicProfile;
|
||||
import com.cloud.vm.ReservationContext;
|
||||
@ -1407,6 +1408,10 @@ public class ConsoleProxyManagerImpl implements ConsoleProxyManager, ConsoleProx
|
||||
}
|
||||
|
||||
if (nic.getTrafficType() == TrafficType.Management) {
|
||||
String mgmt_cidr = _configDao.getValue(Config.ManagementNetwork.key());
|
||||
if (NetUtils.isValidCIDR(mgmt_cidr)) {
|
||||
buf.append(" mgmtcidr=").append(mgmt_cidr);
|
||||
}
|
||||
buf.append(" localgw=").append(dest.getPod().getGateway());
|
||||
}
|
||||
}
|
||||
|
||||
@ -1006,6 +1006,11 @@ public class SecondaryStorageManagerImpl implements SecondaryStorageVmManager, V
|
||||
buf.append(" gateway=").append(nic.getGateway());
|
||||
}
|
||||
if (nic.getTrafficType() == TrafficType.Management) {
|
||||
String mgmt_cidr = _configDao.getValue(Config.ManagementNetwork.key());
|
||||
if (NetUtils.isValidCIDR(mgmt_cidr)) {
|
||||
buf.append(" mgmtcidr=").append(mgmt_cidr);
|
||||
}
|
||||
|
||||
buf.append(" localgw=").append(dest.getPod().getGateway());
|
||||
buf.append(" private.network.device=").append("eth").append(deviceId);
|
||||
} else if (nic.getTrafficType() == TrafficType.Public) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user