Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Main Section Web Server
  • Search

How to take use the phpcgi apache tempalte to run php 5.2

Questions regarding the Web Server
Apache + Nginx, Nginx + PHP5-FPM
Post Reply
  • Print view
Advanced search
1 post • Page 1 of 1
skurudo
VestaCP Team
Posts: 8099
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: How to take use the phpcgi apache tempalte to run php 5.
  • Quote

Post by skurudo » Wed Feb 25, 2015 5:40 am

Well, it's big and scary rake, but you can do it ;)

You need make php 5.2 from source. Then you need change config phpcgi for your site to work with php 5.2

Code: Select all

<VirtualHost 55.139.190.246:8080>

    ServerName domain.ru
    ServerAlias www.domain.ru domain.juvia.ru
    ServerAdmin [email protected]
    DocumentRoot /home/domain/web/domain.ru/public_html
    ScriptAlias /cgi-bin/ /home/domain/web/domain.ru/cgi-bin/
    Alias /vstats/ /home/domain/web/domain.ru/stats/
    Alias /error/ /home/domain/web/domain.ru/document_errors/
    SuexecUserGroup domain domain
    CustomLog /var/log/apache2/domains/domain.ru.bytes bytes
    CustomLog /var/log/apache2/domains/domain.ru.log combined
    ErrorLog /var/log/apache2/domains/domain.ru.error.log
    <Directory /home/domain/web/domain.ru/public_html>
php_admin_value open_basedir /home/domain/web/domain.ru/public_html:/home/domain/tmp
php_admin_value upload_tmp_dir /home/domain/tmp
php_admin_value session.save_path /home/domain/tmp
php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -f [email protected]"
        AllowOverride All
        Options +Includes -Indexes +ExecCGI
      Action phpcgi-script /cgi-bin/php <--- THIS PART
        <Files *.php>
            SetHandler phpcgi-script
        </Files>
    </Directory>
    <Directory /home/domain/web/domain.ru/stats>
        AllowOverride All
    </Directory>
    Include /home/domain/conf/web/apache2.domain.ru.conf*
</VirtualHost>
And your php symlink must be edited too:
#!/usr/bin/php52-cgi -c/home/domain/conf/web/php.ini
first part - where your compiled php is
second - config for your php
Top


Post Reply
  • Print view
1 post • Page 1 of 1

Return to “Web Server”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password