Update php version test

pull/43/head
necro-nemsis 3 years ago
parent 964af787b8
commit 81b2a14055

@ -1,34 +1,40 @@
raspap_dir="/etc/raspap"
raspap_user="www-data"
webroot_dir="/var/www/html"
version=`sed 's/\..*//' /etc/debian_version`
version=$(lsb_release -sc) #``sed 's/\..*//' /etc/debian_version`
# Determine version, set default home location for lighttpd and
# php package to install
if [ $version -eq 11 ]; then
if [ $version -eq bullseye ]; then
version_msg="11.0 (Bullseye)"
sudo apt update --allow-releaseinfo-change
# sudo apt update --allow-releaseinfo-change
php_package="php7.4-cgi"
elif [ $version -eq 10 ]; then
elif [ $version -eq buster ]; then
version_msg="10.0 (Buster)"
php_package="php7.3-cgi"
elif [ $version -eq 9 ]; then
elif [ $version -eq stretch ]; then
version_msg="9.0 (Stretch)"
php_package="php7.0-cgi"
elif [ $version -eq focal ]; then
version_msg="20.02 (Focal)"
php_package="php7.4-cgi"
elif [ $version -eq jammy ]; then
version_msg="22.04 (Jammy)"
php_package="php8.1-cgi"
else
version_msg="Unmatched version use php7.4"
php_package="php7.4-cgi"
fi
phpcgiconf=""
if [ "$php_package" = "php7.4-cgi" ]; then
if [ "$php_package" = "php8.1-cgi" ]; then
phpcgiconf="/etc/php/8.1/cgi/php.ini"
elif [ "$php_package" = "php7.4-cgi" ]; then
phpcgiconf="/etc/php/7.4/cgi/php.ini"
elif [ "$php_package" = "php7.3-cgi" ]; then
phpcgiconf="/etc/php/7.3/cgi/php.ini"
elif [ "$php_package" = "php7.0-cgi" ]; then
phpcgiconf="/etc/php/7.0/cgi/php.ini"
elif [ "$php_package" = "php5.6-cgi" ]; then
phpcgiconf="/etc/php5/cgi/php.ini"
fi
# Outputs a RaspAP Install log line
@ -326,7 +332,7 @@ function patch_system_files() {
"/sbin/wpa_cli -i wlan[0-9] scan_results"
"/sbin/wpa_cli -i wlan[0-9] scan"
"/sbin/wpa_cli -i wlan[0-9] reconfigure"
"/sbin/wpa_cli -i wlan[0-9] select_network"
"/sbin/wpa_cli -i wlan[0-9] select_network"
"/bin/cp /tmp/hostapddata /etc/hostapd/hostapd.conf"
"/etc/init.d/hostapd start"
"/etc/init.d/hostapd stop"

Loading…
Cancel
Save