Nginx配置静态html示例

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/dujianxiong/article/details/86611320
server {
        listen 8180;
        server_name localhost;

        charset utf-8;
        access_log /usr/local/nginx/nginx/logs/v_access.log  main;
        error_log /usr/local/nginx/nginx/logs/v_error.log;

        location / {
            root /usr/local/nginx/nginx/html/v_jiesha;
            index index.html;
        }

        error_page 404 /404.html;
        # redirect server error pages to the static page /50x.html

        error_page 500 502 503 504 /50x.html;
        location = /50x.html {
               root html;
        }
}

猜你喜欢

转载自blog.csdn.net/dujianxiong/article/details/86611320