Nginx自定义错误未显示

时间:2016-02-15 00:18:15

标签: nginx config

我在RHEL上的Nginx配置有问题,我正在尝试配置自定义错误页面,这是我的配置:

server {
    listen 443;
    listen [::]:443;

    ssl on;

    ssl_certificate /etc/nginx/ssl/^/ssl.crt;
    ssl_certificate_key /etc/nginx/ssl/^/ssl.key;
    ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
    ssl_ciphers HIGH:!aNULL:!MD5;
    ssl_prefer_server_ciphers on;  


    server_name   ~^(www\.)?(?P<domain>.+)$;
    root   /www/$domain;
    include /etc/nginx/conf.d/my_domain;
    location ~ ^/(403|404|405|50x).html {
        root /www/^/error;
    }


    location ~ .php$ {
        fastcgi_pass  127.0.0.1:9000;
        fastcgi_index  index.php;
        fastcgi_intercept_errors on;
        fastcgi_param  SCRIPT_FILENAME  /www/$domain$fastcgi_script_name;
        include        fastcgi_params;
    }
}

任何方式我都阅读了所有内容,我不知道该怎么做才能修复它:(在任何人问之前......是的,我已经重新启动了nginx!

0 个答案:

没有答案