@@ -211,8 +211,11 @@ php_install() {
211211 fi
212212 local ver=$( conf_read php-ver)
213213
214- sudo apt -y install php${ver} -common php${ver} -cli php${ver} -fpm php${ver} -curl php${ver} -gd php${ver} -imap php${ver} -readline php${ver} -mysql php${ver} -mbstring php${ver} -bcmath php${ver} -opcache php ${ver} - zip php${ver} -xml php${ver} -soap php${ver} -imagick php${ver} -msgpack php${ver} -igbinary php${ver} -intl php-pear graphviz ghostscript
214+ sudo apt -y install php${ver} -common php${ver} -cli php${ver} -fpm php${ver} -curl php${ver} -gd php${ver} -imap php${ver} -readline php${ver} -mysql php${ver} -mbstring php${ver} -bcmath php${ver} -zip php${ver} -xml php${ver} -soap php${ver} -imagick php${ver} -msgpack php${ver} -igbinary php${ver} -intl php-pear graphviz ghostscript
215215
216+ # Starting with 8.5: Opcache extension is now always bundled in core, cannot be installed separately.
217+ [[ $ver =~ ^(5.6| 7.0| 7.1| 7.2| 7.3| 7.4| 8.0| 8.1| 8.2| 8.3| 8.4)$ ]] && sudo apt -y install php${ver} -opcache
218+
216219 conf_write php true
217220
218221 if [[ -d /etc/php/${ver} /fpm ]] && systemctl is-active --quiet php${ver} -fpm; then
@@ -430,13 +433,13 @@ fastcgi_param HTTP_ACCEPT_ENCODING "";
430433 [[ -n $( conf_read default-response) ]] && sudo webinoly -default-site=$( conf_read default-response)
431434 [[ -n $( conf_read tools-port-set) ]] && sudo webinoly -tools-port=$( conf_read tools-port-set)
432435 [[ -n $( conf_read tools-site) ]] && sudo webinoly -tools-site=$( conf_read tools-site)
433- [[ $( conf_read global-access-log-off) =~ ^(false| purged)$ ]] && sudo log -only-error=off || sudo log -only-error=on
436+ [[ $( conf_read global-access-log-off) =~ ^(false| purged)$ ]] && sudo log -access-log=on || sudo log -access-log=off
434437 [[ -n $( conf_read fastcgi-conf) ]] && sudo webinoly -cache-valid=[$( conf_read fastcgi-conf) ]
435438 [[ -n $( conf_read auth-whitelist-ip) ]] && sudo httpauth -whitelist=$( conf_read auth-whitelist-ip)
436439 [[ -n $( conf_read blockip) ]] && sudo webinoly -blockip=$( conf_read blockip)
437440
438- [[ $( conf_read sftp-www-data) == " true" ]] && sudo webinoly -login-www-data =on
439- [[ $( conf_read sftp-www-data) == " false" ]] && sudo webinoly -login-www-data =off
441+ [[ $( conf_read sftp-www-data) == " true" ]] && sudo webinoly -sftp =on
442+ [[ $( conf_read sftp-www-data) == " false" ]] && sudo webinoly -sftp =off
440443
441444 http_header_referrer
442445 http_header_hsts
@@ -797,7 +800,10 @@ php_tool_memcached() {
797800 local ver=$( conf_read php-ver)
798801
799802 # Memcached (Object Cache)
800- sudo apt -y install php${ver} -memcached php${ver} -memcache memcached
803+ sudo apt -y install php${ver} -memcached memcached
804+
805+ # Starting with 8.5: Memcache module still not available, we should consider remove it permanently.
806+ [[ $ver =~ ^(5.6| 7.0| 7.1| 7.2| 7.3| 7.4| 8.0| 8.1| 8.2| 8.3| 8.4)$ ]] && sudo apt -y install php${ver} -memcache
801807
802808 conf_write php-tool-memcached true
803809
0 commit comments