Step2: (Generate cert file)
mkdir /etc/apache2/ssl RANDFILE=/dev/random openssl req $@ -new -x509 -days 365 -nodes \ -out /etc/apache2/ssl/apache.pem \ -keyout /etc/apache2/ssl/apache.pem chmod 600 /etc/apache2/ssl/apache.pem Step3: (Config for apache2) cd /etc/apache2/sites-available/ cp default ssl Step4: (Enable the site. This is done by making a sym-link to the configuration from /etc/apache2/sites-enabled/.) a2ensite ssl Step5: (To enable the ssl module from /etc/apache2/mods-available) a2enmod ssl Step6: (Add 443 port to /etc/apache2/ports.conf) Listen 443 Step7: (Edit /etc/apache2/sites-available/ssl) NameVirtualHost *:443SSLEngine On SSLCertificateFile /etc/apache2/ssl/apache.pem
Step8: Restart apache2 /etc/init.d/apache2 restart
沒有留言:
張貼留言