In this “how to” we will see how to setup cherokee on Ubuntu with PHP5-FPM (FastCGI Process Manager). Although the cherokee CookBook claims that “If PHP-fpm binaries are found, those will be prioritized over the regular binaries.” it turns out that the latest stable version of cherokee in Launchpad gives errors while enabling it. So here is the work around.
- Add the cherokee PPA and install cherokee
add-apt-repository ppa:cherokee-webserver
apt-get update
apt-get install cherokee
- Add PHP5-FPM PPA, install it and start it
add-apt-repository ppa:brianmercer/php
apt-get install php5-fpm
service php5-fpm start
- Start cherokee admin
cherokee-admin -b
and open http://<your-ip-address>:9090/ in your browser and use the “One-time Password” - Inside the control panel click on “Sources” and click on “+” (Add new information Source) and fill in the connection field with 127.0.0.1:9000 (PHP5-FPM Service port)
- Next, go to “vServers” and click on “Behaviour” tab for the default vServer. Click on “Rule Management”
Go to the “+”(Add Behavior Rule) and click on Manual
- Go to the “Handler” tab and select “FastCGI” as the Handler
Scroll down to the “FastCGI Specific” section and select the “Balancer” as “Round Robin”
Select the “Application Server” as php
- Save and gracefully restart to see the changes.
Test it with phpinfo();
If everything goes OK, you should have a fully functional PHP setup ready on Cherokee.
Pingback: Tweets that mention [How To] Setup Cherokee with PHP5 FPM | TechTatva -- Topsy.com
Pingback: TechTatva.com: [How To] Setup Cherokee with PHP5 FPM | Development Blog With Code Updates : Developercast.com
Pingback: TechTatva.com: [How To] Setup Cherokee with PHP5 FPM | PHP