diff --git a/src/helper/Site_Letsencrypt.php b/src/helper/Site_Letsencrypt.php index 0669eaf1..fbb60520 100644 --- a/src/helper/Site_Letsencrypt.php +++ b/src/helper/Site_Letsencrypt.php @@ -208,7 +208,7 @@ public function authorize( Array $domains, $wildcard = false, $preferred_challen try { $order = $this->client->requestOrder( $domains ); } catch ( \Exception $e ) { - \EE::warning( 'It seems you\'re in local environment or using non-public domain, please check logs. Skipping letsencrypt.' ); + \EE::warning( 'Let\'s Encrypt order request failed (' . $e->getMessage() . '). It seems you\'re in local environment or using non-public domain, please check logs. Skipping letsencrypt.' ); \EE::log( 'You can fix the issue and re-run: ee site ssl-verify ' . $domains[0] ); return false; @@ -405,7 +405,7 @@ public function check( Array $domains, $wildcard = false, $preferred_challenge = $authorizationChallengeToCleanup[] = $authorizationChallenge; } catch ( \Exception $e ) { \EE::debug( $e->getMessage() ); - \EE::warning( 'Challenge Authorization failed. Check logs and check if your domain is pointed correctly to this server.' ); + \EE::warning( 'Challenge Authorization failed (' . $e->getMessage() . '). Check logs and check if your domain is pointed correctly to this server.' ); $site_name = $domains[0]; $site_name = str_replace( '*.', '', $site_name ); @@ -641,19 +641,15 @@ private function executeRenewal( $domain, array $alternativeNames, $force = fals return true; } catch ( \Exception $e ) { - \EE::warning( 'A critical error occured during certificate renewal' ); + \EE::warning( 'A critical error occurred during certificate renewal: ' . $e->getMessage() ); \EE::debug( print_r( $e, true ) ); - - \EE::warning( 'Challenge Authorization failed. Check logs and check if your domain is pointed correctly to this server.' ); - \EE::log( 'You can fix the issue and re-run: ee site ssl-verify ' . $domains[0] ); + \EE::log( 'You can fix the issue and re-run: ee site ssl-verify ' . $domain ); return false; } catch ( \Throwable $e ) { - \EE::warning( 'A critical error occured during certificate renewal' ); + \EE::warning( 'A critical error occurred during certificate renewal: ' . $e->getMessage() ); \EE::debug( print_r( $e, true ) ); - - \EE::warning( 'Challenge Authorization failed. Check logs and check if your domain is pointed correctly to this server.' ); - \EE::log( 'You can fix the issue and re-run: ee site ssl-verify ' . $domains[0] ); + \EE::log( 'You can fix the issue and re-run: ee site ssl-verify ' . $domain ); return false; }