| 在php-fom配置文件加入用户组及sock地址,用户组一定要加,要不然nginx会报13: Permission denied) while connecting to upstream
 
  
  mac 系统的
 所有的用户都属于 staff 组,
 只有具有管理员性质的用户位于 wheel 组中。
 wheel 是一个特殊的用户组,该组的用户可以使用 su 切换到 root,而 staff 组是所有普通用户的集合。
nginx 配置域名
 server
{
    listen  80;
    server_name lv.a.com;
    root /Users/libo/wwwroot/server/lingrb/public;
    location / {
      index  index.html index.htm index.php;
        if (!-e $request_filename){
            rewrite  ^(.*)$  /index.php?s=$1  last;  break;
        }
    }
    location ~ \.php(.*)$ {
        fastcgi_pass     unix:/opt/homebrew/etc/nginx/wwwlogs/CGI.sock;
        #fastcgi_pass 127.0.0.1:9000;
        fastcgi_index  index.php;
        fastcgi_split_path_info  ^((?U).+\.php)(/?.+)$;
        fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
        fastcgi_param  PATH_INFO  $fastcgi_path_info;
        fastcgi_param  PATH_TRANSLATED  $document_root$fastcgi_path_info;
        include          fastcgi_params;
    }
   access_log  /opt/homebrew/etc/nginx/wwwlogs/lv.a.com.log;
   error_log   /opt/homebrew/etc/nginx/wwwlogs/lv.a.com.error.log;
}
 
 mac 按照PHP开发环境 可以查看以下链接https://www.cnblogs.com/duyuanshang/p/php_dev_m1.html
 |