Fix php8.1 package install

This commit is contained in:
VirtuBox
2022-01-25 16:43:55 +01:00
parent 9743a60742
commit c2f0542afa
2 changed files with 19 additions and 12 deletions

View File

@@ -6,7 +6,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
## Releases
### v3.9.x - [Unreleased]
### v3.14.0 - [Unreleased]
#### Added
- PHP 8.0 and 8.1 support
#### v3.13.2 - 2020-10-27

View File

@@ -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 = []
@@ -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: