Compare commits

...

1 Commits

Author SHA1 Message Date
bf5de6a455 fix(2fauth): update PHP version from 8.3 to 8.4 in update_script
The install script uses PHP 8.4, but the update_script was still
checking for and upgrading to PHP 8.3. This aligns the update
with the install configuration.

Also improved the sed pattern to handle any 8.x version.
2025-12-16 14:41:18 +01:00

View File

@ -34,14 +34,14 @@ function update_script() {
msg_info "Creating Backup"
mv "/opt/2fauth" "/opt/2fauth-backup"
if ! dpkg -l | grep -q 'php8.3'; then
if ! dpkg -l | grep -q 'php8.4'; then
cp /etc/nginx/conf.d/2fauth.conf /etc/nginx/conf.d/2fauth.conf.bak
fi
msg_ok "Backup Created"
if ! dpkg -l | grep -q 'php8.3'; then
PHP_VERSION="8.3" PHP_MODULE="common,ctype,fileinfo,mysql,cli,tokenizer,dom,redis,session,openssl" PHP_FPM="YES" setup_php
sed -i 's/php8.2/php8.3/g' /etc/nginx/conf.d/2fauth.conf
if ! dpkg -l | grep -q 'php8.4'; then
PHP_VERSION="8.4" PHP_MODULE="common,ctype,fileinfo,mysql,cli,tokenizer,dom,redis,session,openssl" PHP_FPM="YES" setup_php
sed -i 's/php8\.[0-9]/php8.4/g' /etc/nginx/conf.d/2fauth.conf
fi
fetch_and_deploy_gh_release "2fauth" "Bubka/2FAuth"
setup_composer