logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: Internal resources displayed on external web pages
Author
JeremyGelber



Joined: 08 Sep 2015
Posts: 9
Location: London, UK

PostPosted: Sat 31 Oct '15 8:30    Post subject: Internal resources displayed on external web pages Reply with quote

Hi,

I have a webpage that wraps a webcam such that I access the page using my external FQDN and it then displays both the HTML on the page and also the image from the webcam in a frame.

The way I achieved this was to put a port redirect on my router pointing at the webcam and then simply embed the FQDN with that port after it. That's all fine and good but of course it means the webcam needs its own port forward.

Is there a way to use the INTERNAL IP of the webcam and have Apache translate that on the fly such that no redirect is necessary? Obviously when viewing the webpage on the local network that would work just fine but I'm thinking more about how to get it working behind a NAT firewall.

Thanks,

Jeremy
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7371
Location: Germany, Next to Hamburg

PostPosted: Sat 31 Oct '15 23:12    Post subject: Reply with quote

Sure a reverse proxy is easy to use



in the httpd.conf or a vhost

Code:
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so


ProxyPass / http://192.168.0.1/
ProxyPassReverse / http://192.168.0.1/
Back to top
JeremyGelber



Joined: 08 Sep 2015
Posts: 9
Location: London, UK

PostPosted: Sun 01 Nov '15 13:44    Post subject: Reply with quote

Awesome, thank you. Looking through all the documentation on it now! Smile
Back to top


Reply to topic   Topic: Internal resources displayed on external web pages View previous topic :: View next topic
Post new topic   Forum Index -> Apache