To Configure https In Apache ( Ubuntu )
- First need to enable https
- Create a Folder to store SSL certificate
- Next copy the following certificate to above folder
- SSL CertificateFile (.crt)
- SSL Certificate Key File (.key)
- Certificate Chain file (.crt)
- This certificates can be downloaded form the Certificate authority.
- Also can Self Signed SSL Certificate form following command.
" $ sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/apache2/ssl/apache.key -out /etc/apache2/ssl/apache.crt "
This was copied form https://www.digitalocean.com/community/tutorials/how-to-create-a-ssl-certificate-on-apache-for-ubuntu-12-04
- Next open the SSL configuration file.
$ sudo nano /etc/apache2/sites-available/default-ssl.conf
- Make sure SSL on
# SSLEngine on
- And change the following with the certificate name.
# SSLCertificateFile /etc/apache2/ssl/SSL CertificateFile.crt# SSLCertificateKeyFile /etc/apache2/ssl/SSL Certificate Key File.key
# SSLCertificateChainFile /etc/apache2/ssl/Certificate Chain file.crt
- Save the file.
- Next Open the 443 port from the Firewall
$ sudo ufw allow 443
- Restart the Apache service.
$ sudo service apache2 restart
- In azure to work this also need to open the 443 from Azure port.
# log in the portal and select the Virtual Machine and go to Endpoint and create a endpoint with following config.
I have read this post. collection of post is a nice one. Keep update with us..!!..Azure Online Training
ReplyDelete