Fix php8.1 package install
This commit is contained in:
@@ -274,7 +274,7 @@ class WOSiteUpdateController(CementBaseController):
|
||||
oldsitetype not in ['html', 'proxy', 'php', 'php72',
|
||||
'php73', 'php74', 'php80', 'php81']) or
|
||||
(stype == 'mysql' and oldsitetype not in [
|
||||
'html', 'php', 'php72', 'php73', 'php74','php80', 'php81',
|
||||
'html', 'php', 'php72', 'php73', 'php74', 'php80', 'php81',
|
||||
'proxy']) or
|
||||
(stype == 'wp' and oldsitetype not in [
|
||||
'html', 'php', 'php72', 'php73', 'php74', 'php80', 'php81',
|
||||
@@ -282,7 +282,8 @@ class WOSiteUpdateController(CementBaseController):
|
||||
(stype == 'wpsubdir' and oldsitetype in ['wpsubdomain']) or
|
||||
(stype == 'wpsubdomain' and oldsitetype in ['wpsubdir']) or
|
||||
(stype == oldsitetype and cache == oldcachetype)) and
|
||||
not (pargs.php72 or pargs.php73 or pargs.php74 or pargs.php80 or
|
||||
not (pargs.php72 or pargs.php73 or
|
||||
pargs.php74 or pargs.php80 or
|
||||
pargs.php81)):
|
||||
Log.info(self, Log.FAIL + "can not update {0} {1} to {2} {3}".
|
||||
format(oldsitetype, oldcachetype, stype, cache))
|
||||
@@ -302,7 +303,8 @@ class WOSiteUpdateController(CementBaseController):
|
||||
data = dict(
|
||||
site_name=wo_domain, www_domain=wo_www_domain,
|
||||
static=False, basic=True, wp=False, wpfc=False,
|
||||
php72=False, php73=False, php74=False, php80=False, php81=False,
|
||||
php72=False, php73=False, php74=False,
|
||||
php80=False, php81=False,
|
||||
wpsc=False, wpredis=False, wprocket=False, wpce=False,
|
||||
multisite=False, wpsubdir=False, webroot=wo_site_webroot,
|
||||
currsitetype=oldsitetype, currcachetype=oldcachetype)
|
||||
@@ -329,7 +331,8 @@ class WOSiteUpdateController(CementBaseController):
|
||||
if ((pargs.php72 or pargs.php73 or
|
||||
pargs.php74 or pargs.php80 or pargs.php81) and (not data)):
|
||||
Log.debug(
|
||||
self, "pargs php72, or php73, or php74, or php80, or php81 enabled")
|
||||
self, "pargs php72, or php73, or php74, "
|
||||
"or php80, or php81 enabled")
|
||||
data = dict(
|
||||
site_name=wo_domain,
|
||||
www_domain=wo_www_domain,
|
||||
@@ -475,9 +478,9 @@ class WOSiteUpdateController(CementBaseController):
|
||||
data['php80'] = bool(old_php80 is True)
|
||||
Log.debug(self, "data php80 = {0}".format(data['php80']))
|
||||
php80 = bool(old_php80 is True)
|
||||
data['php80'] = bool(old_php80 is True)
|
||||
Log.debug(self, "data php80 = {0}".format(data['php80']))
|
||||
php80 = bool(old_php80 is True)
|
||||
data['php81'] = bool(old_php81 is True)
|
||||
Log.debug(self, "data php81 = {0}".format(data['php81']))
|
||||
php81 = bool(old_php81 is True)
|
||||
|
||||
if pargs.letsencrypt:
|
||||
acme_domains = []
|
||||
@@ -558,7 +561,7 @@ class WOSiteUpdateController(CementBaseController):
|
||||
(php74 is old_php74) and (php80 is old_php80) and
|
||||
(php81 is old_php81) and
|
||||
(stype == oldsitetype and
|
||||
cache == oldcachetype)):
|
||||
cache == oldcachetype)):
|
||||
Log.debug(self, "Nothing to update")
|
||||
return 1
|
||||
|
||||
@@ -578,8 +581,8 @@ class WOSiteUpdateController(CementBaseController):
|
||||
data['wo_php'] = 'php81'
|
||||
check_php_version = '8.1'
|
||||
else:
|
||||
data['wo_php'] = 'php73'
|
||||
check_php_version = '7.3'
|
||||
data['wo_php'] = 'php80'
|
||||
check_php_version = '8.0'
|
||||
|
||||
if pargs.hsts:
|
||||
data['hsts'] = bool(pargs.hsts == "on")
|
||||
@@ -878,7 +881,7 @@ class WOSiteUpdateController(CementBaseController):
|
||||
# Setup WordPress if old sites are html/php/mysql sites
|
||||
if data['wp'] and oldsitetype in ['html', 'proxy', 'php', 'php72',
|
||||
'mysql', 'php73', 'php74', 'php80',
|
||||
'php81',]:
|
||||
'php81', ]:
|
||||
try:
|
||||
wo_wp_creds = setupwordpress(self, data)
|
||||
except SiteError as e:
|
||||
|
||||
Reference in New Issue
Block a user