Go to file
dependabot[bot] 5697f2c1a2
build(deps): bump github.com/prometheus/client_model from 0.5.0 to 0.6.0
Bumps [github.com/prometheus/client_model](https://github.com/prometheus/client_model) from 0.5.0 to 0.6.0.
- [Release notes](https://github.com/prometheus/client_model/releases)
- [Commits](https://github.com/prometheus/client_model/compare/v0.5.0...v0.6.0)

---
updated-dependencies:
- dependency-name: github.com/prometheus/client_model
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-01 22:07:33 +00:00
.github build(deps): bump codecov/codecov-action from 3 to 4 (#260) 2024-02-01 22:48:40 +00:00
cmd/error-pages chore: 🔧 Changes that do not modify src or test files 2023-02-23 21:50:35 +04:00
internal fix: "Too big request header" (#244) 2023-11-20 12:27:40 +04:00
l10n Fix spanish translated tags (#237) 2023-10-10 15:10:11 +04:00
schemas Go templates support, XML, JSON, Ingress (#49) 2022-01-27 17:29:49 +05:00
templates New template orient added (#190) 2023-04-17 15:06:28 +04:00
test feat: Non-existing pages now return styled 404 status page (with 404 status code) (#189) 2023-04-07 14:42:00 +04:00
.codecov.yml v2: App rewritten in Go (#25) 2021-09-29 20:38:50 +05:00
.dockerignore chore: 🔧 Changes that do not modify src or test files 2023-02-23 21:50:35 +04:00
.editorconfig chore: 🔧 Changes that do not modify src or test files 2023-02-23 21:50:35 +04:00
.gitattributes Update .gitattributes 2022-03-25 14:51:50 +05:00
.gitignore Go templates support, XML, JSON, Ingress (#49) 2022-01-27 17:29:49 +05:00
.golangci.yml depguard disabled 2023-06-04 01:18:45 -07:00
CHANGELOG.md Update CHANGELOG.md 2023-11-20 12:28:22 +04:00
docker-compose.yml chore(deps): update golangci/golangci-lint docker tag to v1.56 (#261) 2024-02-08 09:57:10 +04:00
Dockerfile build(deps): bump golang from 1.21-bullseye to 1.22-bullseye 2024-03-01 22:01:50 +00:00
error-pages.yml New template orient added (#190) 2023-04-17 15:06:28 +04:00
go.mod build(deps): bump github.com/prometheus/client_model from 0.5.0 to 0.6.0 2024-03-01 22:07:33 +00:00
go.sum build(deps): bump github.com/prometheus/client_model from 0.5.0 to 0.6.0 2024-03-01 22:07:33 +00:00
LICENSE Basic repo files added 2020-07-08 16:12:21 +05:00
Makefile chore: 🔧 Changes that do not modify src or test files 2023-02-23 21:50:35 +04:00
README.md Polish translation added. (#226) 2023-09-28 10:51:55 +04:00

banner

22 feb. 2022 - Our Docker image was downloaded one MILLION times from the docker hub!
10 apr. 2023 - Two million times from the docker hub and one million from the ghcr!

One day you may want to replace the standard error pages of your HTTP server with something more original and pretty. That's what this repository was created for :) It contains:

  • Simple error pages generator, written in Go
  • Single-page error page templates with different designs (located in the templates directory)
  • Fast and lightweight HTTP server
  • Already generated error pages (sources can be found here, the demonstration is always accessible here)

🔥 Features list

  • HTTP server written in Go, with the extremely fast FastHTTP under the hood
    • Respects the Content-Type HTTP header (and X-Format) value and responds with the corresponding format (supported formats are json and xml)
    • Writes logs in json format
    • Contains healthcheck endpoint (/healthz)
    • Contains metrics endpoint (/metrics) in Prometheus format
  • Lightweight docker image (~4.6Mb compressed size), distroless and uses the unleveled user by default
  • Go-template tags are allowed in the templates
  • Ready for integration with Traefik (error pages customization) and Ingress-nginx
  • Error pages can be embedded into your own nginx docker image
  • Fully configurable (take a look at the configuration file and project Wiki)
  • Distributed using docker image and compiled binary files
  • Localized (🇺🇸, 🇫🇷, 🇺🇦, 🇷🇺, 🇵🇹, 🇳🇱, 🇩🇪, 🇪🇸, 🇨🇳, 🇮🇩, 🇵🇱) HTML error pages (translation process described here - other translations are welcome!)

🧩 Install

Download the latest binary file for your os/arch from the releases page or use our docker image:

Registry Image
Docker Hub tarampampam/error-pages
GitHub Container Registry ghcr.io/tarampampam/error-pages

Using the latest tag for the docker image is highly discouraged because of possible backward-incompatible changes during major upgrades. Please, use tags in X.Y.Z format

💣 Or you can download already rendered error pages pack as a zip or tar.gz archive.

🛠 Usage

Please, take a look at our Wiki for the common usage stories:

🦾 Performance

Used hardware:

  • Intel® Core™ i7-10510U CPU @ 1.80GHz × 8
  • 16 GiB RAM
$ ulimit -aH | grep file
-f: file size (blocks)              unlimited
-c: core file size (blocks)         unlimited
-n: file descriptors                1048576
-x: file locks                      unlimited

$ docker run --rm -p "8080:8080/tcp" -e "SHOW_DETAILS=true" error-pages:local # in separate terminal

$ wrk --timeout 1s -t12 -c400 -d30s -s ./test/wrk/request.lua http://127.0.0.1:8080/
Running 30s test @ http://127.0.0.1:8080/
  12 threads and 400 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency    10.84ms    7.89ms 135.91ms   79.36%
    Req/Sec     3.23k   785.11     6.30k    70.04%
  1160567 requests in 30.10s, 4.12GB read
Requests/sec:  38552.04
Transfer/sec:    140.23MB
FS & memory usage stats during the test

🪂 Templates

Name Preview
ghost ghost
l7-light l7-light
l7-dark l7-dark
shuffle shuffle
noise noise
hacker-terminal hacker-terminal
cats cats
lost-in-space lost-in-space
app-down app-down
connection connection
matrix matrix
orient orient

Note: noise template highly uses the CPU, be careful

🦾 Contributors

I want to say a big thank you to everyone who contributed to this project:

contributors

📰 Changes log

Release date Commits since latest release

Changes log can be found here.

👾 Support

Issues Issues

If you find any bugs in the project, please create an issue in the current repository.

📖 License

This is open-sourced software licensed under the MIT License.