[TriLUG] SOLVED Re: apache: different DocumentRoot for different IPs
Alan Porter
porter at trilug.org
Mon May 14 11:42:27 EDT 2012
> Not to mention that you'll have to go back and write a second set of
> stanzas when you get dual-stack IPv6 up and running.
I was wondering about that...
When I set up my AlanPorter.com site as dual-stack, I made my
/etc/apache2/sites-available/alanporter.com file like this:
<VirtualHost 207.192.72.89:80>
ServerName alanporter.com
ServerAlias www.alanporter.com
ServerAlias ipv4.alanporter.com
include inc/alanporter.com
</VirtualHost>
<VirtualHost 207.192.72.89:443>
ServerName alanporter.com
ServerAlias www.alanporter.com
ServerAlias ipv4.alanporter.com
include inc/ssl
include inc/alanporter.com
</VirtualHost>
<VirtualHost 2600:3c03::19:2001:80>
ServerName alanporter.com
ServerAlias www.alanporter.com
ServerAlias ipv6.alanporter.com
include inc/alanporter.com
</VirtualHost>
And then I included all of my site-specific and certificate-specific
stuff in separate config files. That way, I am not changing the same
settings in multiple stanzas.
Does this make sense? Am I doing it wrong?
--
# ɹǝʇɹoԀ uɐl∀
More information about the TriLUG
mailing list