I have two hostnames sharing the same domain name which I want to serve over HTTPs. I've got a wildcard-SSL certificate and created two vhost configs:
Host A
listen 127.0.0.1:443 ssl;
server_name a.example.com;
root /data/httpd/a.example.com;
ssl_certificate /etc/ssl/wildcard.cer;
ssl_certificate_key /etc/ssl/wildcard.key;
Host B
listen 127.0.0.1:443 ssl;
server_name b.example.com;
root /data/httpd/b.example.com;
ssl_certificate /etc/ssl/wildcard.cer;
ssl_certificate_key /etc/ssl/wildcard.key;
However, I get the same vhost served for either hostname.