Another fix for wo_update
This commit is contained in:
@@ -959,7 +959,7 @@ class WOSiteUpdateController(CementBaseController):
|
|||||||
pargs.site_name = pargs.site_name.strip()
|
pargs.site_name = pargs.site_name.strip()
|
||||||
(wo_domain, wo_www_domain) = ValidateDomain(pargs.site_name)
|
(wo_domain, wo_www_domain) = ValidateDomain(pargs.site_name)
|
||||||
wo_site_webroot = WOVariables.wo_webroot + wo_domain
|
wo_site_webroot = WOVariables.wo_webroot + wo_domain
|
||||||
wo_domain_type, wo_root_domain = GetDomainlevel(wo_domain)
|
(wo_domain_type, wo_root_domain) = GetDomainlevel(wo_domain)
|
||||||
check_site = getSiteInfo(self, wo_domain)
|
check_site = getSiteInfo(self, wo_domain)
|
||||||
|
|
||||||
if check_site is None:
|
if check_site is None:
|
||||||
@@ -1197,14 +1197,14 @@ class WOSiteUpdateController(CementBaseController):
|
|||||||
return 0
|
return 0
|
||||||
min_expiry_days = 45
|
min_expiry_days = 45
|
||||||
if (expiry_days <= min_expiry_days):
|
if (expiry_days <= min_expiry_days):
|
||||||
renewLetsEncrypt(self, ee_domain)
|
renewLetsEncrypt(self, wo_domain)
|
||||||
if not WOService.reload_service(self, 'nginx'):
|
if not WOService.reload_service(self, 'nginx'):
|
||||||
Log.error(self, "service nginx reload failed. "
|
Log.error(self, "service nginx reload failed. "
|
||||||
"check issues with `nginx -t` command")
|
"check issues with `nginx -t` command")
|
||||||
Log.info(self, "SUCCESS: Certificate was successfully "
|
Log.info(self, "SUCCESS: Certificate was successfully "
|
||||||
"renewed For https://{0}".format(wo_domain))
|
"renewed For https://{0}".format(wo_domain))
|
||||||
elif pargs.force:
|
elif pargs.force:
|
||||||
renewLetsEncrypt(self, ee_domain)
|
renewLetsEncrypt(self, wo_domain)
|
||||||
Log.info(self, "Certificate was successfully renewed")
|
Log.info(self, "Certificate was successfully renewed")
|
||||||
if not WOService.reload_service(self, 'nginx'):
|
if not WOService.reload_service(self, 'nginx'):
|
||||||
Log.error(self, "service nginx reload failed. "
|
Log.error(self, "service nginx reload failed. "
|
||||||
|
|||||||
Reference in New Issue
Block a user