【发布时间】:2016-03-02 23:50:14
【问题描述】:
我的 Nginx 服务器有问题,因为它只显示默认页面。虚拟主机和主机文件似乎没问题。我不明白问题出在哪里。
这是我的虚拟主机配置:
server {
listen 80;
listen [::]:80;
listen 443 default ssl;
server_name marketplace_unirgy;
ssl_certificate /etc/nginx/ssl/nginx.crt;
ssl_certificate_key /etc/nginx/ssl/nginx.key;
root /var/www/html/marketplace_unirgy/;
index index.php;
#location / {
# index index.html index.php;
# autoindex on;
# #If missing pass the URI to Magento's front handler
# try_files $uri $uri/ @handler;
# expires max;
#}
#need it to execute php
location ~ \.php$ {
fastcgi_pass unix:/var/run/php5-fpm.sock;
include fastcgi_params;
include fastcgi.conf;
}
## Magento uses a common front handler
location @handler {
rewrite / /index.php;
}
}
还有我的主人:
127.0.0.1 marketplace_unirgy localhost
我的网站在/var/www/html/marketplace_unirgy
【问题讨论】:
标签: nginx