[PATCH] Start vncconfig for cutNpaste

David Shea dshea at redhat.com
Wed Dec 3 15:41:32 UTC 2014


From: Mark Hamzy <hamzy at us.ibm.com>

Another reason to start vncconfig in a vnc session is to support cut & paste.
---
 pyanaconda/vnc.py | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/pyanaconda/vnc.py b/pyanaconda/vnc.py
index a3a70a7..1b5d875 100644
--- a/pyanaconda/vnc.py
+++ b/pyanaconda/vnc.py
@@ -177,6 +177,16 @@ class VncServer:
                           maxTries), maxTries)
         return False
 
+    def startVncConfig(self):
+        """Attempt to start vncconfig"""
+
+        self.log.info(_("Attempting to start vncconfig"))
+
+        vncconfigcommand = [self.root+"/usr/bin/vncconfig", "-nowin", "-display", ":%s" % self.display]
+
+        # Use startProgram to run vncconfig in the background
+        iutil.startProgram(vncconfigcommand, stdout=self.openlogfile(), stderr=subprocess.STDOUT)
+
     def VNCListen(self):
         """Put the server in listening mode.
 
@@ -256,6 +266,9 @@ class VncServer:
 
         os.environ["DISPLAY"]=":%s" % self.display
 
+        # Start vncconfig for copy/paste
+        self.startVncConfig()
+
     def changeVNCPasswdWindow(self):
         """ Change the password to a sane parameter.
 
-- 
2.1.0



More information about the anaconda-patches mailing list