SSL with multiple virtual hosts and only one IP

Image taken from http://www.artlebedev.com/everything/defendius/

I was writing this long post about how to use rewrite rules to make Apache query itself and serve various sites through the same SSLed virtual host using only one IP. After about four hours of struggling with it I thought I was done but then while writing this article I found out I was wrong. Something was not working as expected. Did I face another 4 hours of Apache struggling?

Each extra IP at my hosting provider, which is great, costs 1$/month. My time is way more expensive than that and I hope yours is too. I was surprised when they asked me to justify the need for a third IP, but SSL certificate was a good enough justification and everything continued painlessly from there.

So, “SSL with multiple virtual hosts and only one IP”: don’t do it, it’s not worth it.

I bet I surprised you with the outcome of this post!

Reviewed by Daniel Magliola. Thank you!


One response to “SSL with multiple virtual hosts and only one IP”

  1. Daniel Magliola Avatar

    For what it’s worth, this happens in IIS too. It’s fundamental to the way SSL works.

    Check here for more detailed answers:
    http://stackoverflow.com/questions/917024/multiple-subdomains-with-ssl-under-iis

Leave a Reply

Hi, I'm Pablo, this is my web site. You can follow me or connect with me:

Or get new content delivered directly to your inbox.

Join 4,025 other subscribers

I'm writing a book

Stack of copies of How to Hire and Manage Remote Teams

How to Hire and Manage Remote Teams, where I distill all the techniques I've been using to build and manage distributed teams for the past 10 years.

I write about:

announcement blogging book book review book reviews books building Sano Business C# Clojure ClojureScript Common Lisp database Debian Esperanto Git history idea Java Kubuntu Lisp music Non-Fiction OpenID programming Python Rails rant re-frame release Ruby Ruby on Rails Sano science science fiction security self-help Star Trek startups technology Ubuntu video web Windows WordPress

I've been writing for a while:

%d bloggers like this: