From 55e919c76e4330650ff157f98ac9f6b915ff76ad Mon Sep 17 00:00:00 2001 From: tbergervoet Date: Tue, 16 Oct 2018 12:40:45 +0200 Subject: [PATCH] Update 'Apache_PHP-FPM_Installer.sh' --- Apache_PHP-FPM_Installer.sh | 43 +++++++------------------------------ 1 file changed, 8 insertions(+), 35 deletions(-) diff --git a/Apache_PHP-FPM_Installer.sh b/Apache_PHP-FPM_Installer.sh index 2e35050..9c5ecfb 100644 --- a/Apache_PHP-FPM_Installer.sh +++ b/Apache_PHP-FPM_Installer.sh @@ -7,38 +7,11 @@ # ##============================================================= -apt remove -y libapache2-mod-php -cat < /etc/apache2/sites-available/"$domain.conf" - - Protocols h2 http/1.1 - #netdata here - ServerAdmin $email - ServerName $domain - ServerAlias www.$domain - DocumentRoot /var/www/$domain/html - - Options FollowSymLinks - AllowOverride All - Order allow,deny - Allow from all - - ErrorLog \${APACHE_LOG_DIR}/error.log - CustomLog \${APACHE_LOG_DIR}/access.log combined - -EOF - -a2enmod actions -mv /etc/apache2/mods-enabled/fastcgi.conf /etc/apache2/mods-enabled/fastcgi.conf.default -cat < /etc/apache2/mods-enabled/fastcgi.conf - - AddHandler fastcgi-script .fcgi - FastCgiIpcDir /var/lib/apache2/fastcgi - AddType application/x-httpd-fastphp .php - Action application/x-httpd-fastphp /php-fcgi - Alias /php-fcgi /usr/lib/cgi-bin/php-fcgi - FastCgiExternalServer /usr/lib/cgi-bin/php-fcgi -socket /run/php/php7.2-fpm.sock -pass-header Authorization - - Require all granted - - -EOF \ No newline at end of file +apachectl stop +apt install -y php-fpm +a2enmod proxy_fcgi setenvif +a2enconf php7.2-fpm +a2dismod php7.2 +a2dismod mpm_prefork +a2enmod mpm_worker +apachectl start \ No newline at end of file