centos php+nginx环境搭建
Posted 野生程序猿
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了centos php+nginx环境搭建相关的知识,希望对你有一定的参考价值。
yum -y install nginx
yum -y i php php-fpm
systemctl start nginx
systemctl start php-fpm
yum install php-bcmath
systemctl reload nginx.service
systemctl reload php-fpm.service
location ~.php$ { try_files $uri = 404; root /work/phpserver; fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi.conf; }
以上是关于centos php+nginx环境搭建的主要内容,如果未能解决你的问题,请参考以下文章
CentOS7.2 上 Nginx PHP Mariadb 环境搭建