diff options
Diffstat (limited to 'abs/core/LinHES-config/mv_vnc.py')
-rwxr-xr-x | abs/core/LinHES-config/mv_vnc.py | 25 |
1 files changed, 5 insertions, 20 deletions
diff --git a/abs/core/LinHES-config/mv_vnc.py b/abs/core/LinHES-config/mv_vnc.py index 0260494..1a028d2 100755 --- a/abs/core/LinHES-config/mv_vnc.py +++ b/abs/core/LinHES-config/mv_vnc.py @@ -79,23 +79,6 @@ exec wmaker logging.info("__End of vnc \n") -def start_xvnc(xvncpasswd): - logging.info(" Checking if x11vnc needs to be started") - if mv_common.check_service("frontend"): - logging.info(" Frontend is running, starting x11vnc") - line='''su mythtv -c "DISPLAY=localhost:0 x11vnc -rfbport 5902 --passwd %s 2>&1 > /dev/null &" \n''' %xvncpasswd - #line='''su mythtv -c "DISPLAY=localhost:0 xscreensaver -no-splash \&" ''' - try: - fout = open("/tmp/cmd.sh", "w") - fout.write(line) - fout.close() - os.chmod("/tmp/cmd.sh",0755) - cmd="/tmp/cmd.sh" - os.system(cmd) - os.remove("/tmp/cmd.sh") - except: - logging.info(" Couldn't start x11vnc") - def setupvnc(systemconfig,data_config): logging.info("____Start of vnc config ____") @@ -114,6 +97,7 @@ def setupvnc(systemconfig,data_config): mv_common.add_service("vnc") else: mv_common.remove_service("vnc") + mv_common.pacremove("tigervnc") #x11vnc try: xvnc=systemconfig.get("xvncenable") @@ -125,9 +109,10 @@ def setupvnc(systemconfig,data_config): if xvnc == "1": logging.info(" Installing x11vnc system\n") mv_common.pacinstall("x11vnc") - start_xvnc(xvncpasswd) + mv_common.add_service("xvnc") else: - mv_common.pacinstall("x11vnc") + mv_common.remove_service("xvnc") + mv_common.pacremove("x11vnc") - logging.info("__End of vnc\n")
\ No newline at end of file + logging.info("__End of vnc\n") |