Skip to content

Commit 0d99f51

Browse files
author
Marius Burkard
committed
- fixed LE command not being called
1 parent c13ab0e commit 0d99f51

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

server/lib/classes/letsencrypt.inc.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,10 @@ public function get_acme_command($domains, $key_file, $bundle_file, $cert_file)
6363
$cmd .= (string) " -d " . $domain;
6464
}
6565

66+
if($cmd == '') {
67+
return false;
68+
}
69+
6670
$cmd = $letsencrypt . " --issue $cmd -w /usr/local/ispconfig/interface/acme && " . $letsencrypt . " --install-cert " . $cmd . " --key-file " . escapeshellarg($key_file) . " --fullchain-file " . escapeshellarg($bundle_file) . " --cert-file " . escapeshellarg($cert_file) . " --reloadcmd " . escapeshellarg($this->get_reload_command());
6771

6872
return $cmd;
@@ -121,6 +125,10 @@ public function get_certbot_command($domains) {
121125
$cmd .= (string) " --domains " . $domain;
122126
}
123127

128+
if($cmd == '') {
129+
return false;
130+
}
131+
124132
$matches = array();
125133
$ret = null;
126134
$val = 0;
@@ -375,7 +383,7 @@ public function request_certificates($data, $server_type = 'apache') {
375383
}
376384

377385
$success = false;
378-
if(!empty($cli_domain_arg)) {
386+
if(!$letsencrypt_cmd) {
379387
if(!isset($server_config['migration_mode']) || $server_config['migration_mode'] != 'y') {
380388
$app->log("Create Let's Encrypt SSL Cert for: $domain", LOGLEVEL_DEBUG);
381389
$app->log("Let's Encrypt SSL Cert domains: $cli_domain_arg", LOGLEVEL_DEBUG);

0 commit comments

Comments
 (0)