I am testing @media statements in a locally hosted website I am building but for the life of me can't hit the site with site_IP/virtual_host_name.
If I have access to the hosts file I simply add (site name) localtest.com into the file along with the IP of the site 192.168.1.X as per normal and all works well. I don't have a rooted phone (my contact wants his site optimised for phone access) so cannot edit the dev hosts file to make the necessary changes. I realise I can use the F12 dev facility to pull different size sites locally but would like to use http://localtest.com as (in my mind) it's the real McCoy. For the life of me I can get it working. I have tried
- http://192.168.1.X/localtest.com
- http://192.168.1.X/var/www/localtest.com (doc root is /var/www in sites-enabled)
and always get a 404. I have checked the access with Wireshark and curl. The request is getting to the server and is answered with the 404. I have an old Windows laptop that confirmed this issue... as soon as I populated the hosts file with the correct entry 192.168.1.X localtest.com
it started displaying properly - using http://localtest.com
UFW isn't blocking port 80
If I http://192.168.1.X I get the UBUNTU Success Page. It's going to be something so stupid. I am sure I have done this before
I hope you are still awake after reading this and you are able to suggest something, I am pulling my hair out.......
Thanks
Kev