Sign inSign up

letsdeal/nginx-error-service

By letsdeal

Updated about 3 years ago

Simple service returning error pages in different formats (for kubernetes NGINX ingress)

Image
0

8.3K

letsdeal/nginx-error-service repository overview

nginx error server

404-server image that provides custom error pages

Description:

The route / expects two headers:

  • X-Code indicates the HTTP code to be returned. Default is 404
  • X-Format the format that should be returned. Default is html

The content to be returned must be a file located inside the directory /var/www/html. Following the previous example, is expected a file named 504.json or 502.html inside /var/www/html. If there is no such file it will try to return the content of the most generic code for the error, ie 5xx for any error bigger than 499 for instance.

How to use it:

  • Create a custom docker image using FROM aledbf/nginx-error-server as parent adding the custom content inside /var/www/html
  • Use aledbf/nginx-error-server image with a custom volume pointing to /var/www/html.

Tag summary

Content type

Image

Digest

Size

44.1 MB

Last updated

almost 5 years ago

docker pull letsdeal/nginx-error-service