• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Shared SSL the easy way.

M

mlovick

Guest
I find it truly amazing that Plesk does not have a direct way of adding shared SSL for plesk domains.

As a recent convert to plesk - i was very disapointed that this feature was not implemented, as our policy is to allow shared SSL for my domain customers to test their sites with.

So i set about looking into the easiest method, which for me involved using apache userDir.

Anyway - here is how I solved the problem.

1. I created a domain with my certificate as I normally would. Tested and working with the SSL certificate on a dedicated IP address.

2. I then created a file named "redirect.php" with the following contents:

PHP:
<?
$user = $_GET["ftp_user"];
header("Location: https\:\/\/[SECURE_DOMAIN]/~$user/");
?>

Where [SECURE_DOMAIN] is the certificate domain.

3. In the conf folder of the secure domain I created a file named "vhost_ssl.conf" with the following content:

PHP:
<IfModule mod_userdir.c>
        UserDir httpdocs
        UserDir enable *
</IfModule>

Then run the following command:

/usr/local/psa/admin/sbin/websrvmng --vhost-name=[SECURE_DOMAIN]

Where [SECURE_DOMAIN] is the certificate domain.

4. after restarting the webserver I logged into Plesk as admin

5. I created a custom button labled "Shared SSL" and with the URL to: https://[SECURE_DOMAIN]/redirect.php

And the checkbox checked: "&ftp_user=<ftp_user>"

Done :) - it works perfectly.
 
Followed the instructions but when I try to pull up a php file or a link to the Miva shopping cart I get an error.

My browser tries to download the php script as a downloadable file instead of processing it.

The Miva error is:
Configuration Error: The configured script directory for 'art'sDomain' does not exist
Please contact the server administrator: webmaster@localhost

Any ideas what I need to do to correct this. I feel like I am so close to actually getting this to work.
Art
 
Back
Top