9

SSH Tunnel on startup

view full story
linux-howto

http://www.linuxquestions.org – I have been banging my head against a wall trying to get this to work. The server is an EC2 instance that I want to tunnel back into a different server. I need this tunnel to get established on startup, but for the life of me cannot get it to work. I have put this line in rc.local hoping it would start: ssh -T -N -i /home/ec2-user/.ssh/id_rsa -L 8080:localhost:80 [email protected] It works great from the command line, but does not work in rc.local. I even tried upstart and created this process called tunnel: Code: start on runlevel [35] stop on runlevel [0126] script  exec ssh -T -N -i (HowTos)