Grant wrote:
What would you do if you needed a certain <Location> block for one
domain but not for another, and you need both of the domains to
function under SSL?  Is multiple IPs the only way?

In my case I'm doing something like this on a single webserver.

head -n 5 /etc/apache2/vhosts.d/02_webapi.domain.com.conf
<VirtualHost 10.77.0.51:443>
ServerName webapi.domain.com
DocumentRoot /var/www/webapi.domain.com/site

head -n 5 /etc/apache2/vhosts.d/03_secure.domain.com.conf
<VirtualHost 10.77.0.61:443>
ServerName secure.domain.com
DocumentRoot /var/www/secure.domain.com/site

I also moved /etc/apache2/modules.d/41_mod_ssl.default-vhost.conf to another dir to keep it from conflicting with the ssl vhosts I have.

You can make ssl work on a single IP if you don't mind all the "this ssl cert is for blah domain not this domain" warnings you'll get from your browser. The reason this happens is that SSL is negotiated before the request for the domain so you'll default to first ssl vhost Apache loaded for that IP.

kashani
--
gentoo-user@gentoo.org mailing list

Reply via email to