HOWTO: PHP 5 CLI to PHP 5 CGI ?

zhaorong65

Verified User
Joined
May 7, 2011
Messages
9
Hello.

I installed Directadmin with PHP5+CLI.
But now i want change CLI to CGI,anyone can tell me how to do it ?

Thanks
 
Hello,

What version of custombuild script do you have?

Code:
grep ^BUILDSCRIPT_VER= /usr/local/directadmin/custombuild/build
 
Hi
BUILDSCRIPT_VER=1.1.42
Thanks

And I do that:
cd /usr/local/directadmin/custombuild
./build update
./build clean
nano options.conf
Then change:
php5_cli=yes
php5_cgi=no
to
php5_cli=no
php5_cgi=yes

./build php n
But there were some 500 errors, old accounts that have permission to 777, have reported an error.
 
Try this:

Code:
cd /usr/local/directadmin/scripts && ./set_permissions.sh user_homes
 find /home/*/domains/*/public_html -type d -print0 | xargs -0 chmod 711
 find /home/*/domains/*/public_html -type f -print0 | xargs -0 chmod 644
 find /home/*/domains/*/public_html -type f -name '*.cgi*' -exec chmod 755 {} \;
 find /home/*/domains/*/public_html -type f -name '*.pl*' -exec chmod 755 {} \;
 find /home/*/domains/*/public_html -type f -name '*.pm*' -exec chmod 755 {} \;
 cd /usr/local/directadmin/data/users && for i in `ls`; do { chown -R $i:$i /home/$i/domains/*/public_html;}; done;
 
Code:
find /home/*/domains/*/public_html -type d -print0 | xargs -0 chmod 711
Shouldn't this be 755?
 
Back
Top