webserver

eric2006

iMovie Professional
I have the built-in web server running with PHP and MySQL. Everything is working on the local network (192.168.1.x), but when I try to access the site externally, I only get the main page. I cannot access any subdirectories. Port forwarding, etc has been enabled. Firefox will "convert" the IP request from (ex) 12.34.56.78/subdirectory to www.my-computer.local/subdirectory - which doesn't work, because it is not on the local network. I need to be able to access the server from the local network as well as externally, as my Comcast router doesn't allow me to connect to the server with its external IP internally (so, from 192.168.1.x and 12.34.56.78 (ex). How do I do this?
 
A quick and dirty way to do this would be to add...

www.my-computer.local to your public ip address in your /etc/hosts file.

Open it and add...

www.my-computer.local xxx.xxx.xxx.xxx

Save the file (you will need to 'sudo nano /etc/hosts' in terminal to edit it) and then run 'lookupd -flushcache' in terminal and it should work for you.
 
Back
Top