73kus-err/README.md

36 lines
826 B
Markdown
Raw Normal View History

2021-08-02 17:19:29 -04:00
# 73k.us custom rainbow error pages (40x/50x)
2021-08-02 17:05:36 -04:00
2021-08-02 17:19:29 -04:00
Based off [frontend-webpack-boilerplate](https://github.com/WeAreAthlon/frontend-webpack-boilerplate) with TailwindCSS added.
2021-08-02 17:05:36 -04:00
Builds html & css that can be used as custom error page templates with caddy.
2021-08-02 17:05:36 -04:00
2021-08-02 17:19:29 -04:00
## NOTE
2021-08-02 17:05:36 -04:00
After production build, optionally remove the empty, 0-byte app.js script tags from the built files, just to optimize things further.
2021-08-02 17:48:22 -04:00
### caddy example
2021-08-02 17:48:22 -04:00
This could probably be optimized but it's working:
```
# Custom Unicorn Rainbow error pages
location /err_css {
root /var/www/err;
autoindex off;
expires max;
}
location /err_images {
root /var/www/err;
autoindex off;
expires max;
}
error_page 403 404 /40x.html;
location = /40x.html {
root /var/www/err;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /var/www/err;
}
```