User wrapper for PHP

Peter Panski
6 December 2017, 12:04
I use UserWebsites = yes but there the php scripts are executed by user www-data. CGI programs are executed by the actual user (WrapUserCGI = yes). How can I configure Hiawatha the same way for php?
Hugo Leisink
6 December 2017, 13:10
If you use PHP via FastCGI, that can't be done. PHP is in that case already running, which makes switching user id impossible. Use PHP via normal CGI (CGIhandler optie). The disadvantage is that PHP is much slower than FastCGI.
Peter Panski
6 December 2017, 13:25
Ok, that makes sense. I will disable FastCGI, I am willing to pay that price. I use different users to separate services. Performance is not required. So is disabling FastCGI enough then?
Hugo Leisink
6 December 2017, 13:34
Disabling FastCGI and of course enabling PHP as normal CGI.
This topic has been closed.