From cd062441f727854306f8b66038f9e5d401df095b Mon Sep 17 00:00:00 2001 From: "Matthew D. Scholefield" Date: Thu, 18 Jan 2018 13:27:42 -0600 Subject: [PATCH] Add info on enabling PHP with httpd This is taken from der_eismann's post on the forums. Source: https://solus-project.com/forums/viewtopic.php?f=11&t=7440&p=21756#p21756 --- software/httpd/en.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/software/httpd/en.md b/software/httpd/en.md index d47b868..980f718 100644 --- a/software/httpd/en.md +++ b/software/httpd/en.md @@ -26,6 +26,29 @@ Therefore, to make modifications to httpd's configuration, you must first create By default, httpd's DocumentRoot is set to `/var/www/`, thus files you desire to be accessible via your httpd server must be copied to that location. +### PHP Support + +To get PHP working, install it from the Software Center or via terminal: + +``` bash +sudo eopkg install php +``` + +Because PHP is loaded via FPM and FastCGI and not via an Apache module, to enable PHP you must create a new file, `/etc/httpd/conf.d/php.conf`, with the following lines: + +``` +LoadModule proxy_module lib64/httpd/mod_proxy.so +LoadModule proxy_fcgi_module lib64/httpd/mod_proxy_fcgi.so + +SetHandler "proxy:fcgi://127.0.0.1:9000" + + +DirectoryIndex index.php index.html + +``` + +[More info here](https://solus-project.com/forums/viewtopic.php?f=11&t=7440&p=21756#p21756). + ### Management Managing httpd is done via systemd, using the following commands: