I'm setting up a mac for local development and have configured dnsmasq.conf with the following:
My wish is to run sites locally by
http://client1.ext.dev/index.html which will map to a local folder of
/www/sites/client1.ext/htdocs/index.html. Of course the variables here are
client# and it's associated
ext which could be any normal TLD -- .com, .net, .info, etc.
I've tried every permutation that I could think of, but I can't seem to get the httpd.conf to map correctly (technically my httpd-vhosts.conf file).
<Virtualhost *:80> VirtualDocumentRoot /www/sites/%-2+/htdocs #ServerName sites.dev ServerAlias *.dev UseCanonicalName Off </Virtualhost>
Using this uri in my browser
client1.com.dev/index.html, my log files reads
File does not exist: /www/sites/client1.com
Why won't the remaining mapping of VirtualDocumentRoot not work? (The "/htdocs" part is not being added.).
Many posts indicate that it should, but the man page (http://goo.gl/Ghff5G) doesn't show any additional directories beyond the %-mapping.
I've also tried RewriteRules within my directives to no avail (and I'm pretty sure I wasn't doing that correctly).
If I have a sub-domain, my browser just goes out to OpenDNS (which I have configured to default after my internal IP) and says it can't find
sub.client1.com.dev which I'd like to map to