安装nginx并启动为服务

https://stackoverflow.com/questions/40846356/run-nginx-as-windows-service

安装 php

下载-设置nssm
https://github.com/Urmuz/Easy-Nginx-PHP

设置 nginx for php

  1. location ~ \.php$ {
  2. root f:/;
  3. fastcgi_pass 127.0.0.1:9000;
  4. fastcgi_index index.php;
  5. # 下面这一句必须加上document__root,否则出现No input file specified.错误
  6. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  7. # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
  8. include fastcgi_params;
  9. }