How to use LocalForward in ssh config file

If you don't want to type 

ssh -L 3306:db.goyun.info:3306 proxy.goyun.info 
everytime, you can put LocalForward in your ~/.ssh/config file:

Host proxy.goyun.info
LocalForward 3306 db.goyun.info:3306

# Tunnels that are set up upon login
#
# LocalForward "110:pop3.example.com:110"
# LocalForward "143:imap.example.com:143"
# LocalForward "25:smtp.example.com:25"
# RemoteForward "3000:localhost:22"
You can use DynamicForward like this:
DynamicForward 1080

Comments

Popular posts from this blog

Check MySQL query history from command line

Installing chocolatey on Windows