I think I finally cracked it.
wget
http://www.suphp.org/download/suphp-0.5.2.tar
tar -zxvf suphp-0.5.2.tar.gz
cd suphp-0.5.2
./configure --with-prefix=/usr --with-apxs=/usr/sbin/apxs --with-min-uid=0 --with-min-gid=0 --with-apache-user=apache --with-php= /usr/bin/php --with-setid-mode=owner
make
make install
pico /etc/httpd/conf/httpd.conf
Look for at the end of file
LoadModule suphp_module /usr/lib/httpd/modules/mod_suphp.so
Delete this line and then add the following in the LoadModule Sections prior to Include conf.d/*.conf
LoadModule suphp_module modules/mod_suphp.so
I only wanted suphp to run on specific sites so there are a couple of options you can do.
As suphp ignores the php_admin_flags in the site vhost.conf files you need to create new php.ini for each site
cp /etc/php.ini /etc/phpvirtual/<domain.com>/php.ini
Then in <domain.com>conf/vhost.conf add the line
suPHP_ConfigPath "/etc/phpvirtual/<domain.com>"
To enable suphp for that entire site add
suPHP_Engine on
However this may affect things like horde and sitebuilder as discussed in other threads. I still haven't checked these out as I only wanted to run suphp on certain directories. I'm running oscommere and it complained if suphp is running on all site so I have only applied it to the admin directory
To do this
pico <domain.com>conf/httpd.include
Find the directory and include the suPHP_Engine On flag
<Directory "/var/www/<domain.com>/httpdocs/admin">
suPHP_Engine On
</Directory>
service httpd restart
And thats it.
I presume that plesk will overite this file so I still nedd to do some experimentation to see if the directory commands can be included in the vhost.conf file. We shall see.
Thanks
