I have a host local-dev
that maps to a VM's IP address.
Theres an AWS EC2 instance running a webserver, to which I want to enable ssh forwarding on a certain port i.e. I want it to forward any requests made to local-dev:85
to the ec2 instance.
local-dev
is also configured with dnsmasq
to support subdomains, and these subdomains must work and be forwarded too.
Whats the best way of doing this? I've tried a bunch of ssh -L
type commands, but they all fail for one reason or another. One of the problems is that the ssh happens for the ec2-user
, and I presume it must happen as root.