Page 1 of 2
PHP-FPM support
Posted: Thu Jun 18, 2015 9:53 pm
by mephivio
hi team
in your website, in the topic version history 0.9.8-14, you tell that you support PHP-FPM
Great !!! : but how to enable it ?
For existing VestaCP (and also for new install) you explain more than a week ago you were finishing a specific script... is it available ?
Despite that, nice work this new release...
thanks
JP
Re: PHP-FPM support
Posted: Sat Jun 20, 2015 7:25 pm
by EvilMoe
Same question
Re: PHP-FPM support
Posted: Sun Jun 21, 2015 12:01 am
by Steven
Web -> Edit Domain -> Web Template (Apache2) -> phpfcgid (perhaps?)
I think a lot of us are getting our knickers tied up with the impending NGINX + PHP-FPM support, however you do not necessarily have to wait for the developers to release this support. You can already do this yourself.
I have been running this control panel for a good while now and it has been very good in production with Nginx only (no apache), PHP-FPM, and MariaDB. All you have to do is install the binaries and configure your own Web Templates.
Re: PHP-FPM support
Posted: Sun Jun 21, 2015 7:47 am
by EvilMoe
Do you have a working template for us with FPM and seperate PHP.ini for us?
EDIT: phpfcgid is not PHP FPM, it is FCGI
Re: PHP-FPM support
Posted: Sun Jun 21, 2015 10:17 am
by Steven
I think first off, read this page to understand the difference between FCGI and FPM
http://stackoverflow.com/questions/4526 ... gi-and-fpm
Essentially we are speaking the same language. From that page "FPM is a process manager". Hey I don't care as long as it works right?
Perhaps the developers of VestaCP misinterpreted this too, or perhaps they have really found a way to have everyones' web public directories chowned as the user:group and.. somehow managed to figure out how to allow applications like WordPress can have proper access to wp-content etc - I know I am still trying to find that sweet spot. (otherwise www-data:www-data does the trick)
Or perhaps they are onto this already, and hence why we are waiting for this. It isn't easy.
There isn't anything important required to change in the php.ini - just need your own template for nginx. Note that until the developers release a version that completely eliminates Apache - the templates will need to take full control of port 80, without any pass_proxy to apache. In other words, apache can run quite happily in the background, but it won't be used at all.
The directory of interest is:
/usr/local/vesta/data/templates/web/nginx
The files ending in
.tpl are templates for normal traffic on port 80.
The files ending in
.stpl are templates for secure traffic on port 443.
My configuration is quite complex. However I can offer the advice that as you have nginx accepting everything on port 80, handling PHP files is simply a
location block pointing to either a socket at
/var/run/php5-fpm.sock or
127.0.0.1:9000.
*edit - I am happy to assist further, it is just difficult to post long and winding lengths of code. All you have to do is make sure that nginx takes over everything without passing anything to apache. Remember that nginx is in front of apache anyway - so if you've got the handlers in place to deal with the static files, PHP files, and security stuff, nothing will get passed to apache. You could already just
apt-get remove apache and vestacp wouldn't complain.
Re: PHP-FPM support
Posted: Mon Jun 22, 2015 1:22 pm
by imperio
Now we are testing new installer for centos 7 and php-fpm
Re: PHP-FPM support
Posted: Sat Jun 27, 2015 8:41 pm
by Botrax
How is PHP-FPM enabled in Vesta CP? Support is there, but how is it used/enabled?
Default Apache template?
Default NGINX template?
how?
Re: PHP-FPM support
Posted: Sun Jun 28, 2015 9:00 pm
by Steven
Botrax wrote:How is PHP-FPM enabled in Vesta CP? Support is there, but how is it used/enabled?
Default Apache template?
Default NGINX template?
how?
You install this PHP yourself.
You create your own template for VestaCP to use. Have a look in the directories I posted above. Learn how they are constructed. You'll be looking at using port 9000 or passing queries through to a socket for PHP.
Re: PHP-FPM support
Posted: Wed Jul 01, 2015 11:19 am
by mephivio
Hi imperio
is your next script for php-fpm is ready ?
thx
J
Re: PHP-FPM support
Posted: Wed Jul 01, 2015 12:42 pm
by imperio
Ready, but not released yet