Use local php. Part 3

This commit is contained in:
Alexey Berezhok
2025-01-18 15:55:12 +03:00
parent 2f91eee76d
commit f3b9d33016
10 changed files with 161 additions and 139 deletions

View File

@@ -67,14 +67,14 @@ csv_list() {
declare -a versions
# List through /etc/php
if [ -f /etc/redhat-release ]; then
for version in /etc/opt/remi/php*/php-fpm.d/www.conf; do
ver=$(echo "$version" | awk -F"/" '{ print $5 }' | sed "s/php\([[:digit:]]\+\)/\1/g")
if [ "$LOCAL_PHP" == "yes" ]; then
for version in /opt/brepo/php*/etc/php-fpm.d/www.conf; do
ver=$(echo "$version" | awk -F"/" '{ print $4 }' | sed "s/php\([[:digit:]]\+\)/\1/g")
versions+=("$ver")
done
else
for version in /etc/php/*/fpm/pool.d/www.conf; do
ver=$(echo "$version" | awk -F"/" '{ print $4 }')
for version in /etc/opt/remi/php*/php-fpm.d/www.conf; do
ver=$(echo "$version" | awk -F"/" '{ print $5 }' | sed "s/php\([[:digit:]]\+\)/\1/g")
versions+=("$ver")
done
fi