Question
How to allow HTTPS and configure an SSL certificate on a domain in Plesk which has Hosting Type set as Forwarding in Domains > example.com > Hosting Settings?
Answer
Warning: Currently, it's possible to secure a forwarding domain only when Nginx is installed and enabled on the server.
To secure a domain with the Forwarding hosting type with an SSL certificate perform the following (commands are the same for Linux SSH terminal and Windows CMD):
-
Check if the Common Challenge directory is enabled on the server.
If the output of the command is as below:# plesk ext sslit --common-challenge-dir -info
- Available: true
- Enabled: falseExecute the next command to enable the Common Challenge directory:
# plesk ext sslit --common-challenge-dir -enable
-
Go to Domains > example.com > SSL/TLS Certificates where
example.com
is a domain with hosting type Forwarding and install a Let's Encrypt or the certificate from 3rd party certificate authorities.To secure a Forwarding hosting type domain with a free Let's Encrypt certificate via CLI
use the below command:
# plesk ext sslit --certificate -issue -domain example.com -registrationEmail [email protected] -secure-domain
Where:
- example.com is the name of the domain with Forwarding hosting type.
- [email protected] is the email address.
-
-secure-domain is the option for securing the domain name. For other available options check
plesk ext sslit --help
.