AMH panel SSL extended to site Configure SSL domain name certificate tutorial

Source: Internet
Author: User
Tags prepare account security ssl certificate

However, for ordinary personal sites, to date has not been said to use the SSL domain name certificate, but some similar to the consumer interaction and account security class site must be used, even if not for the site in search engine experience needs, but also the user's information is responsible. In previous posts, Lao left also shared several configurations of SSL domain name certificates in other common environments.

Old left before simple to the common Apache, Nginx, Litespeed environment to configure SSL to share the article. This article is based on the AMH panel environment to configure SSL, in the last week when a netizen proposed to solve the problem, due to the time issue today (most of the time the tutorial is very troublesome, in order to be authentic, you must apply for a certificate, also need to deploy the environment).

First, preparatory work


We need to prepare a few points before we need to configure the domain name site SSL certificate for the AMH panel:


A-The AMH panel has been built and the site is already bound


B-The SSL certificate that has been applied for, prepare the "for Nginx" certificate file, one is. CRT, and one is. key file.


C-Need to authenticate reading articles, steps to execute.


second, deploy the SSL extension module

Log in to the AMH panel background, search for SSL in the module extension area, and locate the SSL module shown above, and then download it.

Return to the list of modules, and then install the SSL module extensions that you just downloaded.

Third, deploy SSL certificate files

Then we deploy the SSL certificate to prepare the work for us. Key and. CRT two files, open with sublime, and then copy the script inside, paste into the corresponding text box to save. (if there are multiple sites in the AMH, check if the site you need to deploy SSL is selected)

Four, forced to jump HTTPS Web site

So far, if we deploy the domain name and then we can open the URL with the SSL certificate directly via HTTPS, how do we solve it if we need to force a jump to HTTPS?

The code is as follows Copy Code
/usr/local/nginx/conf/vhost/

In the above directory, locate the. conf file for the site, and then edit.

The code is as follows Copy Code
if ($server _port = 80) {
return https://$server _name$request_uri;
}
if ($scheme = http) {
return https://$server _name$request_uri;
}
Error_page 497 https://$server _name$request_uri;


Add a script from the face to the document, as shown in the following figure.



After the deployment is replaced, the execution of the AMH nginx restart reboot Nginx can take effect.


In summary, AMH Panel deployment SSL Domain certificate is relatively simple, do not need too many modifications and configuration files, directly in the module extension can be completed.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.