Difference between revisions of "PHP"

From wiki
(Integrate with nginx)
Line 1: Line 1:
{{Debian}}{{WIP}}<syntaxhighlight lang="console">
+
{{Debian}}{{WIP}}
 +
 
 +
== Prerequisite ==
 +
 
 +
To use this guide, you will need [[Nginx]] installed and configured.
 +
 
 +
== Installation ==
 +
 
 +
<syntaxhighlight lang="console">
 
# apt install php5-cli php5-fpm php5-apcu
 
# apt install php5-cli php5-fpm php5-apcu
 
</syntaxhighlight>
 
</syntaxhighlight>
 +
 +
== Configuration ==
 +
 +
=== Integrate with Nginx ===
 +
 +
Create file <code>/etc/nginx/conf.d/php5.conf</code>
 +
<syntaxhighlight lang="nginx">
 +
upstream php {
 +
    server unix:/var/run/php5-fpm.sock;
 +
}
 +
</syntaxhighlight>
 +
 +
 
[[Category:Linux Server]]
 
[[Category:Linux Server]]
 +
[[Category:Web Server]]

Revision as of 10:27, 19 March 2016

Warning Warning: These instructions were only tested on Debian. It will probably work for other Linux distributions, but you might need to adapt the provided instructions.
Warning Warning: This page is a work in progress and is not completed. Important informations might be missing or wrong.

Prerequisite

To use this guide, you will need Nginx installed and configured.

Installation

# apt install php5-cli php5-fpm php5-apcu

Configuration

Integrate with Nginx

Create file /etc/nginx/conf.d/php5.conf

upstream php {
    server unix:/var/run/php5-fpm.sock;
}