PDA

View Full Version : Php with Apache rights, not vhost rights


BenDaDon
6th October 2005, 21:35
Hello guys,
i've a big problem:
All my PhpScripts are running under Apache2 Rights, like wwwrun.
So Typo3 (the php script) creates files under the username wwwrun.
i would like to have the same username and -group like the virtualhost.
I think Suexec doesnt work correct.
What to do?
suexec2 -V:

-D AP_DOC_ROOT="/srv/www"
-D AP_GID_MIN=96
-D AP_HTTPD_USER="wwwrun"
-D AP_LOG_EXEC="/var/log/apache2/suexec.log"
-D AP_SAFE_PATH="/usr/local/bin:/usr/bin:/bin"
-D AP_UID_MIN=96
-D AP_USERDIR_SUFFIX="public_html"

That's not really the DOC ROOT which i use...!
But to change this, i have to compile it ( man suexec2 ).
So whats the solution ? ;)
Guys i count on you....

falko
7th October 2005, 04:29
suExec is only for CGI scripts (e.g. Perl scripts). If you run PHP as CGI (and not as an Apache module), then suExec is for you. But mostly PHP runs as an Apache module, so you might have a look at suPHP (http://www.suphp.org/Home.html).

ddelbia
8th January 2006, 13:03
You are the best! I love you ;-)

P.S. For Debian user:

apt-get install libapache2-mod-suphp (for apache)
or
apt-get install libapache-mod-suphp (for apache2)

falko
8th January 2006, 19:24
P.S. For Debian user:

apt-get install libapache2-mod-suphp (for apache)
or
apt-get install libapache-mod-suphp (for apache2)
I think it's the other way round: :D

apt-get install libapache2-mod-suphp (for Apache2)
or
apt-get install libapache-mod-suphp (for Apache)