【发布时间】:2014-04-10 22:36:20
【问题描述】:
我刚刚按照本教程在我的 ubuntu vps 上安装了带有 nginx 的 Laravel 4: https://www.digitalocean.com/community/articles/how-to-install-laravel-with-nginx-on-an-ubuntu-12-04-lts-vps
Evertything 似乎安装得很好,但是当浏览它的 ip 地址时,我仍然得到:
有效!
这是此服务器的默认网页。 Web 服务器软件正在运行,但尚未添加任何内容。
我认为这可能与虚拟主机有关,但似乎也配置正确
server {
listen 80 default_server;
root /var/www/laravel/public/;
index index.php index.html index.htm;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
# pass the PHP scripts to FastCGI server listening on /var/run/php5-fpm.sock
location ~ \.php$ {
try_files $uri /index.php =404;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}
会有人知道我做错了什么吗? 谢谢!
【问题讨论】: