If it's barking that 'SSLCertificateFile' is a invalid directive, then you don't have mod_ssl loaded. You need a line somewhere in your config that looks similar to this:

LoadModule ssl_module   libexec/apache22/mod_ssl.so

(That particular line is from a FreeBSD box, so it's unlikely to work without minor modification)

You should usually put the SSL information in the vhost's directive; but a very simple site could go something like this:

ServerName example.com

Listen 80
Listen 443

LoadModule ssl_module   libexec/apache22/mod_ssl.so
LoadModule the other modules go in here...

User www
Group www

DocumentRoot /path/to/site

SSLCertificateFile /path/to/cert
SSLCertificateKeyFile /path/to/key
SSLCertificateChainFile /path/to/chain

<VirtualHost *:443>
    SSLEngine on
</VirtualHost>

This is what the config for my person site looks like (plus some security, logging, and other junk like that).


I think it's better for you to put the SSL information inside the vhost that will use it, just for organization's sake. Also remember that mod_ssl has to be enabled on apache for the SSLEngine, SSLCertificateFile and SSLCertificateKeyFile to work.

# a2enmod ssl

Will normally enable the module automatically in debian based distributions.