zoukankan      html  css  js  c++  java
  • php-fpm 在centos 7下的安装配置

    安装php:

    sudo yum install php php-fpm php-mysql php-mbstring php-mcrypt php-sockets php-curl php-common php-xml php-soap

    启动php-fpm:

    sudo systemctl start php-fpm

    设置自动启动:

    sudo systemctl enable php-fpm

    查看启动是否成功:

    ps aux | grep php-fpm

    配置nginx通过fast-cgi方式支持php:

    vi /etc/nginx/conf.d/default.conf 
    
    # 去掉文件里已经有的类似这一段的注释,可以根据自己的需要修改, 如果配置文件里没有也可以自己加上。
    
        location ~ .php$ {
              root           html;
              fastcgi_pass   127.0.0.1:9000;
              fastcgi_index  index.php;
              fastcgi_param  SCRIPT_FILENAME  /scripts$fastcgi_script_name;
              include        fastcgi_params;
        }
  • 相关阅读:
    【leetcode】二叉搜索树的最近公共祖先
    052-12
    052-11
    052-10
    052-9
    052-8
    052-6
    052-5
    052-3
    052-2
  • 原文地址:https://www.cnblogs.com/afxcn/p/4783522.html
Copyright © 2011-2022 走看看