mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-07 22:06:05 +01:00
bu fix: wp manager version fetch
This commit is contained in:
@@ -1974,8 +1974,8 @@ class CloudManager:
|
|||||||
except:
|
except:
|
||||||
path = '/home/%s/public_html' % (self.data['domain'])
|
path = '/home/%s/public_html' % (self.data['domain'])
|
||||||
|
|
||||||
command = 'wp core version --skip-plugins --skip-themes --path=%s' % (path)
|
command = 'wp core version --skip-plugins --skip-themes --path=%s 2>/dev/null' % (path)
|
||||||
finalDic['version'] = str(ProcessUtilities.outputExecutioner(command, website.externalApp))
|
finalDic['version'] = str(ProcessUtilities.outputExecutioner(command, website.externalApp, True))
|
||||||
|
|
||||||
## LSCache
|
## LSCache
|
||||||
|
|
||||||
@@ -2633,8 +2633,8 @@ class CloudManager:
|
|||||||
|
|
||||||
path = '/home/%s/public_html' % (self.data['domainName'])
|
path = '/home/%s/public_html' % (self.data['domainName'])
|
||||||
|
|
||||||
command = 'wp core version --allow-root --skip-plugins --skip-themes --path=%s' % (path)
|
command = 'wp core version --allow-root --skip-plugins --skip-themes --path=%s 2>/dev/null' % (path)
|
||||||
result = ProcessUtilities.outputExecutioner(command)
|
result = ProcessUtilities.outputExecutioner(command, None, True)
|
||||||
|
|
||||||
if result.find('Error:') > -1:
|
if result.find('Error:') > -1:
|
||||||
final_dic = {'status': 0, 'fetchStatus': 0,
|
final_dic = {'status': 0, 'fetchStatus': 0,
|
||||||
|
|||||||
@@ -799,9 +799,9 @@ class WebsiteManager:
|
|||||||
php = ACLManager.getPHPString(PHPVersion)
|
php = ACLManager.getPHPString(PHPVersion)
|
||||||
FinalPHPPath = '/usr/local/lsws/lsphp%s/bin/php' % (php)
|
FinalPHPPath = '/usr/local/lsws/lsphp%s/bin/php' % (php)
|
||||||
|
|
||||||
command = 'sudo -u %s %s -d error_reporting=0 /usr/bin/wp core version --skip-plugins --skip-themes --path=%s' % (
|
command = 'sudo -u %s %s -d error_reporting=0 /usr/bin/wp core version --skip-plugins --skip-themes --path=%s 2>/dev/null' % (
|
||||||
Vhuser, FinalPHPPath, path)
|
Vhuser, FinalPHPPath, path)
|
||||||
version = ProcessUtilities.outputExecutioner(command)
|
version = ProcessUtilities.outputExecutioner(command, None, True)
|
||||||
version = html.escape(version)
|
version = html.escape(version)
|
||||||
|
|
||||||
command = 'sudo -u %s %s -d error_reporting=0 /usr/bin/wp plugin status litespeed-cache --skip-plugins --skip-themes --path=%s' % (
|
command = 'sudo -u %s %s -d error_reporting=0 /usr/bin/wp plugin status litespeed-cache --skip-plugins --skip-themes --path=%s' % (
|
||||||
@@ -1480,9 +1480,9 @@ class WebsiteManager:
|
|||||||
|
|
||||||
###fetch WP version
|
###fetch WP version
|
||||||
|
|
||||||
command = 'sudo -u %s %s -d error_reporting=0 /usr/bin/wp core version --skip-plugins --skip-themes --path=%s' % (
|
command = 'sudo -u %s %s -d error_reporting=0 /usr/bin/wp core version --skip-plugins --skip-themes --path=%s 2>/dev/null' % (
|
||||||
Vhuser, FinalPHPPath, path)
|
Vhuser, FinalPHPPath, path)
|
||||||
version = ProcessUtilities.outputExecutioner(command)
|
version = ProcessUtilities.outputExecutioner(command, None, True)
|
||||||
version = version.rstrip("\n")
|
version = version.rstrip("\n")
|
||||||
|
|
||||||
###install wp core
|
###install wp core
|
||||||
|
|||||||
Reference in New Issue
Block a user