Ok, so, still a n00b with setting up VHosts and all, but I'm curious how this is working...
So there is a new domain pointing to the server IP, but no VHosts are setup for this particular domain. When people enter in the URL, they see a website for another domain.
So, here's the thing... with no VHost setup, why are they seeing any page at all?
I setup a VHost for the domain, so now anyone visiting the URL is greeted with Forbidden... but I'm curious why this was needed.
Guess my question is, from someone more experienced with the Apache config, is this... does one of the sites in the config show up as a 'Default' site? Is there something I'm missing to deny access when there is no defined location for a domain, rather then people just being tossed to one of the other sites?
It's a bit late, I'm a bit tired, sorry if this isn't typed all correctly. Hope I made this clear, if not, I'll try to clarify if any questions are asked. Basically to sum it up... new domain with no vhost configured points to a different domain on the apache server, kinda like it defaults to it... how do I prevent this?
Apache Site Shows With No VHost
-
- A semi-regular
- Posts: 26
- https://www.youtube.com/channel/UC40BgXanDqOYoVCYFDSTfHA
- Joined: Fri Feb 18, 2011 2:02 pm
-
- A semi-regular
- Posts: 26
- Joined: Fri Feb 18, 2011 2:02 pm
Re: Apache Site Shows With No VHost
Replying with the fix...
http://httpd.apache.org/docs/2.0/vhosts/examples.html
Under - Using _default_ vhosts
Problemo solved!
http://httpd.apache.org/docs/2.0/vhosts/examples.html
Under - Using _default_ vhosts
Problemo solved!
Re: Apache Site Shows With No VHost
Thanks for posting a follow-up!
-
- A semi-regular
- Posts: 26
- Joined: Fri Feb 18, 2011 2:02 pm
Re: Apache Site Shows With No VHost
No problem. May someone else save some time by reading this, if they have the similar setup.Edge100x wrote:Thanks for posting a follow-up!
Found out that with no default page, when it checks the VHosts, it will use the first defined one available, if none are found for a matching domain/port. I did not know that. Seems like it would just deny access and not allow any page to be served... but guess not. ^-^