Build web base KVM console with noVNC and SSH Tunnel

Description


noVNC is a HTML5 VNC client that runs well in any modern browser including mobile browsers (iOS and Android).


Many companies, projects and products have integrated noVNC including Ganeti Web Manager, OpenStack,OpenNebula, LibVNCServer, and ThinLinc. See the Projects and Companies wiki page for a more complete list with additional info and links.


But VMs typically located in a private network behind firewall, thus we can build a KVM Hub and forward the port from the Hub which have public visibilities to all the VMs via the private interface.


Step1: Establish Port forward to the garget VM from the KVM Hub.
ssh  -N -fR 10.124.116.109:49003:10.113.82.141:3388 [email protected]
ssh  -NfL 10.113.82.141:3388:10.3.40.176:5917 [email protected]


Step2:
Use the launch script to start a mini-webserver and the WebSockets proxy (websockify). The --vnc option is used to specify the location of a running VNC server:


./utils/launch.sh --vnc 10.124.116.109:49003


Point your browser to the cut-and-paste URL that is output by the launch script. Enter a password if the VNC server has one configured. Hit the Connect button and enjoy!
Build web base KVM console with noVNC and SSH Tunnel