December 2018
Beginner
826 pages
22h 54m
English
LocalForwarding can even be used to access hosts that the remote machine can see, but your local one can't.
Consider the following configuration entry:
Host * IdentityFile ~/.ssh/id_ed25519 Port 22Host CentOS2-V4 Hostname 192.168.33.11 LocalForward 7777 192.168.33.12:6666 User vagrant
In this example, centos2 can see the host with the IP 192.168.33.12, and the server it's got listening on port 6666.
When we connect to centos2 and create our tunnel, we can connect locally to 127.0.0.1:7777, viewing the web server on 192.168.33.12:6666.
Read now
Unlock full access