From 9e356a00eac7a4c45cc38177e5dfa7a806dc620b Mon Sep 17 00:00:00 2001
From: tbrehm <t.brehm@ispconfig.org>
Date: Tue, 23 Dec 2008 09:34:29 -0500
Subject: [PATCH] Fixed php cgi configuration.
---
server/conf/vhost.conf.master | 30 ++++++++++++++----------------
INSTALL_OPENSUSE_11.txt | 1 +
INSTALL_DEBIAN_4.0.txt | 1 +
INSTALL_DEBIAN_LENNY.txt | 2 +-
INSTALL_UBUNTU_8.04.txt | 1 +
5 files changed, 18 insertions(+), 17 deletions(-)
diff --git a/INSTALL_DEBIAN_4.0.txt b/INSTALL_DEBIAN_4.0.txt
index b0a2b72..23d866b 100644
--- a/INSTALL_DEBIAN_4.0.txt
+++ b/INSTALL_DEBIAN_4.0.txt
@@ -68,6 +68,7 @@
a2enmod suexec
a2enmod rewrite
a2enmod ssl
+a2enmod actions
4) Install pure-ftpd and quota
diff --git a/INSTALL_DEBIAN_LENNY.txt b/INSTALL_DEBIAN_LENNY.txt
index 17f35ad..a042576 100644
--- a/INSTALL_DEBIAN_LENNY.txt
+++ b/INSTALL_DEBIAN_LENNY.txt
@@ -87,7 +87,7 @@
# Then run the following to enable the Apache modules suexec, rewrite and ssl:
-a2enmod suexec rewrite ssl
+a2enmod suexec rewrite ssl actions
# Secure phpMyAdmin by deleting setuppassword-file
# and removing/commenting Setup Authorization from apache.conf
diff --git a/INSTALL_OPENSUSE_11.txt b/INSTALL_OPENSUSE_11.txt
index f76dd41..0f8e0d9 100644
--- a/INSTALL_OPENSUSE_11.txt
+++ b/INSTALL_OPENSUSE_11.txt
@@ -80,6 +80,7 @@
a2enmod suexec
a2enmod rewrite
a2enmod ssl
+a2enmod actions
chkconfig --add apache2
/etc/init.d/apache2 start
diff --git a/INSTALL_UBUNTU_8.04.txt b/INSTALL_UBUNTU_8.04.txt
index e5417e2..cc467c3 100644
--- a/INSTALL_UBUNTU_8.04.txt
+++ b/INSTALL_UBUNTU_8.04.txt
@@ -45,6 +45,7 @@
a2enmod rewrite
a2enmod ssl
a2enmod include
+a2enmod actions
3.1) Optional: Install SuPHP
diff --git a/server/conf/vhost.conf.master b/server/conf/vhost.conf.master
index b7492e1..9cb294a 100644
--- a/server/conf/vhost.conf.master
+++ b/server/conf/vhost.conf.master
@@ -51,6 +51,10 @@
<tmpl_if name='php' op='==' value='mod'>
# mod_php enabled
AddType application/x-httpd-php .php .php3 .php4 .php5
+ php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -fwebmaster@<tmpl_var name='domain'>"
+ php_admin_value upload_tmp_dir <tmpl_var name='document_root'>/tmp
+ php_admin_value session.save_path <tmpl_var name='document_root'>/tmp
+ #php_admin_value open_basedir <tmpl_var name='document_root'>:/usr/share/php5
</tmpl_if>
<tmpl_if name='php' op='==' value='suphp'>
# suphp enabled
@@ -63,7 +67,9 @@
</tmpl_if>
<tmpl_if name='php' op='==' value='cgi'>
# php as cgi enabled
- AddType application/x-httpd-php .php .php3 .php4 .php5
+ ScriptAlias /php5-cgi /usr/bin/php5-cgi
+ Action php5-cgi /php5-cgi
+ AddHandler php5-cgi .php .php3 .php4 .php5
</tmpl_if>
<tmpl_if name='php' op='==' value='fast-cgi'>
# php as fast-cgi enabled
@@ -83,13 +89,6 @@
RewriteCond %{HTTP_HOST} ^<tmpl_var name='rewrite_domain'> [NC]
RewriteRule ^/(.*)$ <tmpl_var name='rewrite_target'>$1 [<tmpl_var name='rewrite_type'>]
</tmpl_loop>
-</tmpl_if>
-<tmpl_if name='php' op='!=' value=''>
-
- php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -fwebmaster@<tmpl_var name='domain'>"
- php_admin_value upload_tmp_dir <tmpl_var name='document_root'>/tmp
- php_admin_value session.save_path <tmpl_var name='document_root'>/tmp
- #php_admin_value open_basedir <tmpl_var name='document_root'>:/usr/share/php5
</tmpl_if>
<tmpl_var name='apache_directives'>
@@ -153,6 +152,10 @@
<tmpl_if name='php' op='==' value='mod'>
# mod_php enabled
AddType application/x-httpd-php .php .php3 .php4 .php5
+ php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -fwebmaster@<tmpl_var name='domain'>"
+ php_admin_value upload_tmp_dir <tmpl_var name='document_root'>/tmp
+ php_admin_value session.save_path <tmpl_var name='document_root'>/tmp
+ #php_admin_value open_basedir <tmpl_var name='document_root'>:/usr/share/php5
</tmpl_if>
<tmpl_if name='php' op='==' value='suphp'>
# suphp enabled
@@ -163,7 +166,9 @@
</tmpl_if>
<tmpl_if name='php' op='==' value='cgi'>
# php as cgi enabled
- AddType application/x-httpd-php .php .php3 .php4 .php5
+ ScriptAlias /php5-cgi /usr/bin/php5-cgi
+ Action php5-cgi /php5-cgi
+ AddHandler php5-cgi .php .php3 .php4 .php5
</tmpl_if>
<tmpl_if name='php' op='==' value='fast-cgi'>
# php as fast-cgi enabled
@@ -184,13 +189,6 @@
RewriteCond %{HTTP_HOST} ^<tmpl_var name='rewrite_domain'> [NC]
RewriteRule ^/(.*)$ <tmpl_var name='rewrite_target'>$1 [<tmpl_var name='rewrite_type'>]
</tmpl_loop>
-</tmpl_if>
-<tmpl_if name='php' op='!=' value=''>
-
- php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -fwebmaster@<tmpl_var name='domain'>"
- php_admin_value upload_tmp_dir <tmpl_var name='document_root'>/tmp
- php_admin_value session.save_path <tmpl_var name='document_root'>/tmp
- #php_admin_value open_basedir <tmpl_var name='document_root'>:/usr/share/php5
</tmpl_if>
<tmpl_var name='apache_directives'>
--
Gitblit v1.9.1