In my development work, I often have to imitate live servers on my development machine. Up to this point, I’ve only ever had to have one site using a secure certificate. Today I had to setup a second site, and thought I would post what I did.
First, I added the line to /etc/httpd/conf.d/ssl.conf above the first VirtualHost directive:
I then changed the existing VirtualHost definition from:
Once that was completed, I then copied the entire VirtualHost container, specifying the new domain, web root, etc. Once saved, I restarted Apache:
sudo /etc/init.d/httpd restart
Voila! I have two sites I can call via my locally signed certificate on 1 machine.