I have one ip address (xx.xx.xx.50) and need it to answer normally on 80 and 443 (no problem, done). However, I have a php program (we'll call Sugar) in /var/www/Sugar/ I need Apache to allow /Sugar ONLY on port 3035 (could be any port, I just picked that one) That works too. HOWEVER, I need port 3035 closed to the outside world, and need to be able to create an ssh tunnel to my localhost so I can just browse to localhost:3035 and connect to the remote machine on port 3035. I've done this with Zope and it works great, but trying the same setup now results in a "channel 3: open failed: connect failed: Connection refused"
The following is the last part of my httpd.conf
Listen xx.xx.xx.50:80
Listen xx.xx.xx.50:3035
NameVirtualHost xx.xx.xx.50:80
NameVirtualHost xx.xx.xx.50:3035
<VirtualHost xx.xx.xx.50:80>
ServerName oliver2.domain.com
DocumentRoot /var/www/html/
</VirtualHost>
<VirtualHost xx.xx.xx.50:3035>
ServerName cane.domain.com
DocumentRoot /var/www/Sugar/
</VirtualHost>
I know this works as I can connect locally via lynx
Perhaps my tunnel command is wrong? I'm using
ssh
user@xx.xx.xx.50 -L 3035:localhost:3035
Any help would be great. Thanks.