Last active
October 18, 2023 05:47
-
-
Save diginc/9219680 to your computer and use it in GitHub Desktop.
How to connect to KVM-QEMU guests over SSH SOCKS Proxy. EXAMPLE of how to setup VNC for ALL your guests, without having to port forward/port tunnel every single 590# number
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ # EXAMPLE of how to setup VNC for ALL your guests, without having to port forward/port tunnel every single 590# number | |
$ cat ~/.ssh/config | |
# Host Machines | |
Host host_a.prod.domain.com | |
User diginc | |
DynamicForward 127.0.0.1:1080 | |
# Used with VNCViewer (RealVNC) like so (FullColor fixes the immediate disconnect bug) | |
# `vncviewer --ProxyServer=127.0.0.1:1080 --ProxyType=socks --FullColor 127.0.0.1:5901` | |
$ cat ~/.bash_aliases | |
# VNC Aliases for hosts | |
for PORT in `seq 5900 5920` ; do | |
alias host_a_${PORT}="vncviewer --ProxyServer=127.0.0.1:1080 --ProxyType=socks --FullColor 127.0.0.1:${PORT}" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment