This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Switch Xdebug state for different PHP configurations | |
PHP_VERSIONS=($(ls /etc/php/ | grep -E '^[0-9]+\.[0-9]+$')) | |
PHP_SAPI=("cli" "fpm") # Add more SAPIs if needed | |
APACHE_RESTART_COMMAND="sudo /etc/init.d/apache2 restart" | |
for version in "${PHP_VERSIONS[@]}"; do | |
for sapi in "${PHP_SAPI[@]}"; do | |
# Restart PHP-FPM service for the current version |
OlderNewer