# SSL/HTTPS
LAMP deployment package has installed the SSL module of Apache and open Certificate Authority Let's Encrypt (opens new window) for you configure the HTTPS quickly and conveniently.
In addition to the vhost configuration file, HTTPS settings do not need to modify any files in Apache
# Quick start
# Automatic deployment
If you want to use a free certificate, just run the one command sudo certbot
on your instance to start the HTTPS deployment.
sudo certbot
# Manual deployment
If you have applied for a commercial certificate, complete the HTTPS configuration in just three steps:
- Upload your certificate to the directory of your instance: /data/cert
- Edit the vhost configuration file: /etc/httpd/conf.d/vhost.conf
- Insert the HTTPS template into
<VirtualHost *:443>--</VirtualHost>
and modify certificate path#-----HTTPS template start------------ <VirtualHost *:443> ServerName mysite1.yourdomain.com DocumentRoot "/data/wwwroot/mysite1" #ErrorLog "logs/mysite1.yourdomain.com-error_log" #CustomLog "logs/mysite1.yourdomain.com-access_log" common <Directory "/data/wwwroot/mysite1"> Options Indexes FollowSymlinks AllowOverride All Require all granted </Directory> SSLEngine on SSLCertificateFile /data/cert/mysite1.yourdomain.com.crt SSLCertificateKeyFile /data/cert/mysite1.yourdomain.com.key SSLCertificateKeyFile /data/cert/mysite1.yourdomain.com.key </VirtualHost> #-----HTTPS template end------------
- Save file and Restart Apache service
# Special Guide
For details on configuring HTTPS pre-conditions, HTTPS configuration segment templates, precautions, detailed steps, and troubleshooting, refer to the HTTPS Special Guide (opens new window) provided by Websoft9
← SMTP Backup & Restore →