Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm sure there's a well-known answer for this, but I can't seem to find it.

How do I make a user's PHP scripts (in ~user/public_html, for example), run as the owner rather than as www-data ?

Assume Apache, Linux, and PHP 5

share|improve this question

1 Answer 1

One option is to use suPHP.

http://www.suphp.org/DocumentationView.html?file=apache/INSTALL

The suPHP Apache module together with suPHP itself provides an easy way to run PHP scripts with different users on the same server.

It provides security, because the PHP scripts are not run with the rights of the webserver's user.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.