From 00e86eec61a4c2a366d4625fdfd677651c91adf4 Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 27 Feb 2018 13:29:24 +0100 Subject: [PATCH 1/2] DietPi-Software | PHP: Buster support for Lighttpd + Nginx --- dietpi/dietpi-software | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index e70cf693f8..7f37ca5113 100644 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -3529,7 +3529,7 @@ _EOF_ if [ -d /var/lib/mysql ]; then G_DIETPI-NOTIFY 2 '/var/lib/mysql exists, will migrate containing databases' - G_RUN_CMD cp -a /var/lib/mysql/* "$G_FP_DIETPI_USERDATA/mysql/" + G_RUN_CMD cp -a /var/lib/mysql/. "$G_FP_DIETPI_USERDATA/mysql" fi @@ -3543,7 +3543,7 @@ _EOF_ G_DIETPI-NOTIFY 2 "Creating symlink: /var/lib/mysql -> $G_FP_DIETPI_USERDATA/mysql" G_RUN_CMD ln -sf "$G_FP_DIETPI_USERDATA/mysql" /var/lib/mysql - chown -R mysql:mysql "$G_FP_DIETPI_USERDATA/mysql" &> /dev/null + G_RUN_CMD chown -R mysql:mysql "$G_FP_DIETPI_USERDATA/mysql" G_AGI mariadb-server @@ -7801,8 +7801,14 @@ _EOF_ cp /DietPi/dietpi/conf/nginx.conf /etc/nginx/nginx.conf # - Stretch , set php7.0 - if (( $G_DISTRO >= 4 )); then + if (( $G_DISTRO == 4 )); then + sed -i "s#/run/php5-fpm.sock#/run/php/php7.0-fpm.sock#g" /etc/nginx/nginx.conf + + elif (( $G_DISTRO > 4 )); then + + sed -i "s#/run/php5-fpm.sock#/run/php/php7.2-fpm.sock#g" /etc/nginx/nginx.conf + fi # - CPU core count @@ -7830,10 +7836,14 @@ _EOF_ #Configure fastcgi for PHP-FPM local fp_php_fpm_sock='/var/run/php/php7.0-fpm.sock' - if (( $G_DISTRO == 3 )); then + if (( $G_DISTRO < 4 )); then fp_php_fpm_sock='/var/run/php5-fpm.sock' + elif (( $G_DISTRO > 4 )); then + + fp_php_fpm_sock='/var/run/php/php7.2-fpm.sock' + fi cat << _EOF_ > /etc/lighttpd/conf-available/15-fastcgi-php.conf @@ -12103,7 +12113,7 @@ _EOF_ # cat << _EOF_ > /etc/systemd/system/moode-worker.service # [Unit] # Description=moOde worker.php service -# After=php7.0-fpm.service php5-fpm.service apache2.service lighttpd.service nginx.service +# After=php7.2-fpm.service php7.0-fpm.service php5-fpm.service apache2.service lighttpd.service nginx.service # [Service] # Type=forking From 7af814d50775d9b2502809746466ceaeb43a73bf Mon Sep 17 00:00:00 2001 From: MichaIng Date: Tue, 27 Feb 2018 13:33:24 +0100 Subject: [PATCH 2/2] v6.3 + DietPi-Services | Add Buster php7.2-fpm service --- dietpi/dietpi-services | 1 + 1 file changed, 1 insertion(+) diff --git a/dietpi/dietpi-services b/dietpi/dietpi-services index 5b5a4f99a9..59eb2ce293 100644 --- a/dietpi/dietpi-services +++ b/dietpi/dietpi-services @@ -45,6 +45,7 @@ 'lighttpd' 'php5-fpm' 'php7.0-fpm' + 'php7.2-fpm' 'mysql' 'mpd' 'ympd'