Skip to content

afeiship/bad-gateway-pages

Repository files navigation

bad-gateway-pages

Custom Bad Gateway Pages.

version license size download

installation

npm install -S @jswork/bad-gateway-pages

usage

#site-wide error pages
server {
  listen 80 default_server;
  listen [::]:80 default_server ipv6only=on;

  set $bad_gataway_pages "/YOUR_PATH/node_modules/@jswork/bad-gataway-pages/dist";

  error_page 404 /404.html;
  location = /404.html {
    root $bad_gataway_pages;
    internal;
  }

  error_page 410 /410.html;
  location = /410.html {
    root $bad_gataway_pages;
    internal;
  }

  error_page 500 502 503 504 /502.html;
  location = /502.html {
    root $bad_gataway_pages;
    internal;
  }
}

resources

license

Code released under the MIT license.