better verbose output

This commit is contained in:
CanbiZ
2025-07-22 11:47:41 +02:00
parent 513f618f38
commit 13af56a077

View File

@@ -438,15 +438,14 @@ function setup_php() {
# install apache2 with PHP support if requested
if [[ "$PHP_APACHE" == "YES" ]]; then
if ! dpkg -l | grep -q "libapache2-mod-php${PHP_VERSION}"; then
msg_info "Installing Apache with PHP${PHP_VERSION} support"
$STD apt-get install -y apache2 libapache2-mod-php${PHP_VERSION}
else
msg_info "Apache with PHP${PHP_VERSION} already installed skipping install"
$STD msg_info "Installing Apache with PHP${PHP_VERSION} support"
$STD apt-get install -y apache2 libapache2-mod-php"${PHP_VERSION}"
$STD msg_ok "Setup Apache with PHP${PHP_VERSION}"
fi
fi
# setup / update PHP modules
$STD apt-get install -y $MODULE_LIST
$STD apt-get install -y "$MODULE_LIST"
msg_ok "Setup PHP $PHP_VERSION"
# optional stop old PHP-FPM service
@@ -485,8 +484,8 @@ function setup_php() {
# enable and restart PHP-FPM if requested
if [[ "$PHP_FPM" == "YES" ]]; then
if systemctl list-unit-files | grep -q "php${PHP_VERSION}-fpm.service"; then
$STD systemctl enable php${PHP_VERSION}-fpm
$STD systemctl restart php${PHP_VERSION}-fpm
$STD systemctl enable php"${PHP_VERSION}"-fpm
$STD systemctl restart php"${PHP_VERSION}"-fpm
else
msg_warn "FPM requested but service php${PHP_VERSION}-fpm not found"
fi