diff --git a/templates/etc-apache2-sites-available-default b/templates/etc-apache2-sites-available-default
index 88d0208559c782fc3f7459f3b65b048d0e656ff3..64814bb250781f4177df6a8a91ea1976d3513afd 100644
--- a/templates/etc-apache2-sites-available-default
+++ b/templates/etc-apache2-sites-available-default
@@ -3,7 +3,7 @@
 
   ServerAdmin {{apache_server_admin}}
 
-{% if not php_fpm_socket|default(false) %}
+{% if php_fpm|default(true) and not php_fpm_socket|default(false) %}
   ProxyPassMatch ^/(.*\.php(/.*)?)$ fcgi://127.0.0.1:9000/var/www{{apache_server_default_root}}/$1
   ProxyTimeout 900
   <Proxy fcgi://127.0.0.1:9000>