Last active
July 12, 2019 14:58
-
-
Save dipu-bd/58bda452dba49b6ed9c9cb160b8d9dbc to your computer and use it in GitHub Desktop.
Configure ssh for to use a proxy to connect to target server
This file contains hidden or 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
Host proxy # A name for the proxy server | |
Hostname <PROXY_SERVER_IP> # Provide the IP address of the proxy server | |
User root # The user to connect to in proxy server | |
Host targetA # A name to access to the Target Server A | |
ProxyCommand ssh -q proxy nc -q0 <TARGET_A_SERVER_IP> 22 | |
Host targetB # A name to access to the Target Server B | |
ProxyCommand ssh -q proxy nc -q0 <TARGET_B_SERVER_IP> 22 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment