Source: http://ubuntuforums.org/showthread.php?t=791804

setup

1. sudo apt-get install apache2
2. sudo apt-get install openssl
3. sudo apt-get install ssl-cert

create ssl certificate:
sudo make-ssl-cert /usr/share/ssl-cert/ssleay.cnf /etc/ssl/private/localhost.pem

switch to apache sites configuration:
cd /etc/apache2/sites-available/

bakup the default configuration:
sudo cp default default.backup.date

be sure to listen the port 80 for the default:
sudo sed -i ‘1,2s/\*/*:80/’ default

create the ssl configuration:
sudo cp default ssl

set the ssl port:
sudo sed -i ‘1,2s/\*:80/*:443/’ ssl
sudo sed -i “3a\\\tSSLEngine On\n\tSSLCertificateFile /etc/ssl/private/localhost.pem” ssl

enable ssl:
sudo a2ensite ssl
sudo a2enmod ssl

restart apache2:
sudo /etc/init.d/apache2 restart

Popularity: 19% [?]

Tags: ,

2 Responses to “Configure Apache SSL Certificate in Ubuntu 8.04”

  1. Lucian says:

    It seems not to be working “out of the box”, needing small tweaks.
    You could add also the generation of a local/test SSL certificate. I am still having problems with this.

  2. Leo says:

    Hello,

    What kind of errors do you have on /var/log/apache2/error.log ?

    Leonardo

Leave a Reply

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="">