I would like to use mod_proxy to test a website I am building on a local virtual machine from my phone. My network looks like this:
IP 1: 10.10.10.2
IP 2: 10.211.55.2
OSX 10.8.2 / Apache 2.2.22
Win7 / IIS 7.5
Configured to use 10.0.0.2:80 as a proxy
iPhone iOS 6.0.1
I've inserted the following into http.conf:
ProxyRequests On ProxyVia On <Proxy *> Order deny,allow Deny from all Allow from 10.0.0 </Proxy> <VirtualHost *:80> ServerName example.local ServerAlias *.example.local ProxyRemote http://example.local/* http://10.211.55.3:80 ErrorLog "/private/var/log/apache2/example-error_log" CustomLog "/private/var/log/apache2/example-access_log" common </VirtualHost>
My /etc/hosts (on host OSX machine) currently doesn't reference example.local. Previously I have had a reference in /etc/hosts (on host OSX machine) and was able to view the site on the IIS guest from the host without any issue. Hence I believe the IIS guest is correctly configured to accept HTTP requests.
I am able to view a site hosted on Apache from my phone and am able to visit the BBC's site. Without the proxy configured on my phone I am unable to view the website hosted on Apache, but am able to view the BBC's website. Hence, I believe the phone is correctly configured.
This leaves configuring Apache. I've tested the config with apachectl -t and no errors are reported. I am unable to see any errors reported in the log files /var/log/example-error_log, /var/log/example-access_log, /var/log/error_log and /var/log/access_log.
I would be very grateful if anyone could point me in the right direction.
Many thanks, Chris