[Ovirt-devel] [PATCH] Update auto-allocated vnc port syntax

Arthur Clement aclement at linagora.com
Thu Aug 26 08:20:02 UTC 2010


http://libvirt.org/formatdomain.html

"vnc"
    Starts a VNC server. The port attribute specifies the TCP port number (with -1 as legacy syntax indicating that it should be auto-allocated). The autoport attribute is the new preferred syntax for indicating autoallocation of the TCP port to use. The listen attribute is an IP address for the server to listen on. The passwd attribute provides a VNC password in clear text. The keymap attribute specifies the keymap to use. 

Signed-off-by: Arthur Clement <aclement at linagora.com>
---
 src/task-omatic/task_vm.rb |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/task-omatic/task_vm.rb b/src/task-omatic/task_vm.rb
index cc2071f..3a197f9 100644
--- a/src/task-omatic/task_vm.rb
+++ b/src/task-omatic/task_vm.rb
@@ -104,7 +104,7 @@ def create_vm_xml(name, uuid, memAllocated, memUsed, vcpus, bootDevice,
   }
 
   doc.root.elements["devices"].add_element("input", {"type" => "mouse", "bus" => "ps2"})
-  doc.root.elements["devices"].add_element("graphics", {"type" => "vnc", "port" => "-1", "listen" => "0.0.0.0"})
+  doc.root.elements["devices"].add_element("graphics", {"type" => "vnc", "autoport" => "yes", "listen" => "0.0.0.0"}) 
 
   doc.root.add_element("features")
   doc.root.elements["features"].add_element("acpi")
-- 
1.7.2.1




More information about the ovirt-devel mailing list