diff --git a/server/plugins-available/apache2_plugin.inc.php b/server/plugins-available/apache2_plugin.inc.php index a39e2080536befdf1ad7067f11fa0cab9609b006..c824ac2525117abb2b21db9fe8f54fca9633b3ec 100644 --- a/server/plugins-available/apache2_plugin.inc.php +++ b/server/plugins-available/apache2_plugin.inc.php @@ -1250,12 +1250,20 @@ class apache2_plugin { // useless data unset($subdomains); unset($temp_domains); - - $crt_tmp_file = "/etc/letsencrypt/live/".$domain."/cert.pem"; + + if(version_compare($app->system->getapacheversion(true), '2.4.8', '>=')) { + $crt_tmp_file = "/etc/letsencrypt/live/".$domain."/fullchain.pem"; + } else { + $crt_tmp_file = "/etc/letsencrypt/live/".$domain."/cert.pem"; + } $key_tmp_file = "/etc/letsencrypt/live/".$domain."/privkey.pem"; $bundle_tmp_file = "/etc/letsencrypt/live/".$domain."/chain.pem"; if(!is_dir("/etc/letsencrypt/live/".$domain)) { - $crt_tmp_file = "/etc/letsencrypt/live/www.".$domain."/fullchain.pem"; + if(version_compare($app->system->getapacheversion(true), '2.4.8', '>=')) { + $crt_tmp_file = "/etc/letsencrypt/live/www.".$domain."/fullchain.pem"; + } else { + $crt_tmp_file = "/etc/letsencrypt/live/www.".$domain."/cert.pem"; + } $key_tmp_file = "/etc/letsencrypt/live/www.".$domain."/privkey.pem"; $bundle_tmp_file = "/etc/letsencrypt/live/www.".$domain."/chain.pem"; }