Martin Polednik has uploaded a new change for review. Change subject: graphics: use global displayNetwork if no local specified ......................................................................
graphics: use global displayNetwork if no local specified Engine can either specify the displayNetwork on global or local basis. If specified locally everything works, but global configuration is ignored for explicitly sent graphics devices. This patch adds logic to decide if local or global displayNetwork is to be used. Change-Id: I537e294fe64d3d2a559f3c77c43c9c845e0b9fda Bug-Url: https://bugzilla.redhat.com/1261007 Signed-off-by: Martin Polednik <[email protected]> --- M vdsm/virt/vmdevices/graphics.py 1 file changed, 9 insertions(+), 2 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/56/46356/1 diff --git a/vdsm/virt/vmdevices/graphics.py b/vdsm/virt/vmdevices/graphics.py index 03d9a20..695982f 100644 --- a/vdsm/virt/vmdevices/graphics.py +++ b/vdsm/virt/vmdevices/graphics.py @@ -56,8 +56,15 @@ super(Graphics, self).__init__(conf, log, **kwargs) self.port = LIBVIRT_PORT_AUTOSELECT self.tlsPort = LIBVIRT_PORT_AUTOSELECT - self.specParams['displayIp'] = _getNetworkIp( - self.specParams.get('displayNetwork')) + + # It's possible that the network is specified vm's conf + # and not in specParams. This is considered legacy. + self.specParams['displayNetwork'] = ( + self.specParams.get('displayNetwork') or conf.get('displayNetwork') + ) + + self.specParams['displayIp'] = ( + _getNetworkIp(self.specParams.get('displayNetwork'))) def getSpiceVmcChannelsXML(self): vmc = vmxml.Element('channel', type='spicevmc') -- To view, visit https://gerrit.ovirt.org/46356 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I537e294fe64d3d2a559f3c77c43c9c845e0b9fda Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: ovirt-3.6 Gerrit-Owner: Martin Polednik <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
