Apache ServerAlias Foo
I was knocking about in my httpd.conf today because I noticed that undefined VirtualHosts were being handled by the last VirtualHost entry defined. I can make a ServerAlias *.involution.com, but I only want that to work for everything that’s not defined by other entries. The problem is I have a cadre of other VitrualHosts defined for my domain that I don’t want handled by the main entry. For example, rpm.involution.com is handled by a different VirtualHost entry than the involution.com one with the *.involution.com alias. The other catch is I don’t want malformed domain requests going to an incorrect VirtualHost entry because it borks the logging. The only way I could make this work is by putting the entry with ServerAlias *.involution.com after all of the other VirtualHost entries for involution.com in httpd.conf which makes sense logically. Is this the correct way to handle this scenario or is there an easier way?
Trackbacks
Use this link to trackback from your own site.






