tarampampam / error-pages

🚧 Pretty server's error pages in the docker image & git repository (for traefik, k8s, nginx and so on)
https://tarampampam.github.io/error-pages/
MIT License
833 stars 81 forks source link

Custom static-pages ( no error pages, but default-backend related ) #216

Open fuog opened 1 year ago

fuog commented 1 year ago

Is there an existing issue for this?

Describe the problem to be solved

Hello, first of all, thank you very much for this great project. I like to use this project in different situations. I would like to ask if it would be possible to extend the tool with the following feature:

I am interested in more usecases for simple static-pages which from my ops point of view could run best directly integrated in the "defaultbackend" so this tool.

Currently I am establishing the /.well-known/security.txt on the loadbalancers. See background. This is a static TXT which I would like to read via configmap or similar.

Why here? Because I like the logging, the lightweight implementation and the deployment without filesystem-access.

Suggest a solution

The way of request-handling could be triggered via 'static-path' or better a request header Static-Page: foobar (e.g. set by the loadbalancer). maybe also an ENV variable with a comma separated list of static pages as path or header-value (value=filename) to include.

Additional context

I'm not sure if this is beyond the scope of this tool from your point of view, I think it would be a good extension. Would there be interest in such a feature? kind regards