用vagrant 配置了環境,但是死活都是‘file not found’
vagrant版本
Vagrant 1.6.5
目錄許可權是
drwxr-xr-x 1 vagrant vagrant
nginx 報錯資訊
[error] 2186#0: *32 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 192.168.33.1, server: xxx.xxx.com, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:"
nginx配置
server { listen 80; ## listen for ipv4; this line is default and implied server_name xxx.xxx.com; root /vagrant/demo; index index.php; # Make site accessible from http://localhost/ if (!-e $request_filename) { rewrite ^(.*)$ /index.php$1 last; } location ~ [^/]\.php(/|$) { fastcgi_split_path_info ^(.+?\.php)(/.*)$; fastcgi_pass unix:/var/run/php5-fpm.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; }}
網上的都試過了,還是不行。
回複內容:
用vagrant 配置了環境,但是死活都是‘file not found’
vagrant版本
Vagrant 1.6.5
目錄許可權是
drwxr-xr-x 1 vagrant vagrant
nginx 報錯資訊
[error] 2186#0: *32 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream, client: 192.168.33.1, server: xxx.xxx.com, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:"
nginx配置
server { listen 80; ## listen for ipv4; this line is default and implied server_name xxx.xxx.com; root /vagrant/demo; index index.php; # Make site accessible from http://localhost/ if (!-e $request_filename) { rewrite ^(.*)$ /index.php$1 last; } location ~ [^/]\.php(/|$) { fastcgi_split_path_info ^(.+?\.php)(/.*)$; fastcgi_pass unix:/var/run/php5-fpm.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; }}
網上的都試過了,還是不行。