centos7 install lnmp

时间:2018-05-18 23:14:53   收藏:0   阅读:238

 centos7 install lnmp

yum install epel-release
yum install php php-fpm nginx mariadb-devel mariadb-server mariadb

test php 模块

vim /etc/nginx/nginx.conf
notice:在location 下面添加这一行就可以

location ~* \.php$ {
  fastcgi_pass 127.0.0.1:9000;
  fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  fastcgi_param PATH_INFO $fastcgi_script_name;
  include fastcgi_params;
  }
最后:在nginx网站的根目录添加01.php 文件
vi 01.php
<?php

  phpinfo();

?>

原文:https://www.cnblogs.com/S--S/p/9058344.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!