Add snippet 'get-path-of-php-command.sh' and change concerning code..

This commit is contained in:
2023-08-03 00:11:02 +02:00
parent 1df7bb124b
commit d84294cf0b
18 changed files with 287 additions and 117 deletions

View File

@ -282,6 +282,7 @@ if [[ "$DATABASE_TYPE" = "postgres" ]]; then
fi
fi
NGINX_IS_ENABLED=false
APACHE2_IS_ENABLED=false
@ -289,10 +290,17 @@ APACHE2_IS_ENABLED=false
#
source ${snippet_dir}/get-webservice-environment.sh
# Check PHP Version
#
source ${snippet_dir}/get-php-major-version.sh
# Get full qualified PHP command
#
source ${snippet_dir}/get-path-of-php-command.sh
CURRENT_INSTALL_DIR="$(realpath ${WEB_BASE_DIR}/nextcloud)"
CURRENT_VERSION="$(basename $CURRENT_INSTALL_DIR | cut -d"-" -f2)"
@ -310,6 +318,8 @@ echo -e " Webserver group......................: $HTTP_GROUP"
echo ""
echo -e " PHP version..........................: $PHP_VERSION"
echo -e " PHP Engine...........................: $PHP_ENGINE"
echo ""
echo -e " PHP Command..........................: $PHP_BIN"
echo ""
echo -n " Type upper case 'YES' to continue executing with this parameters: "
@ -515,7 +525,7 @@ echo ""
# - Create missing indices
# -
echononl " Add missing indices .."
su -c "/usr/local/php/bin/php ${WEB_BASE_DIR}/htdocs/occ db:add-missing-indices" -s /bin/bash $HTTP_USER > $log_file 2>&1
su -c "${PHP_BIN} ${WEB_BASE_DIR}/htdocs/occ db:add-missing-indices" -s /bin/bash $HTTP_USER > $log_file 2>&1
if [[ $? -eq 0 ]]; then
echo_ok
else