- Notifications
You must be signed in to change notification settings - Fork2
Varnish Docker image that also caches POST requests
License
zazuko/varnish-post
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
This Docker image let you cache GET and POST requests.
For POST requests, it will not cache requests with no body or with an empty body.
You can pull the Docker image using:
docker pull ghcr.io/zazuko/varnish-post
It is listening on the 80 port.
You can use following environment variables for configuration:
BACKEND_HOST: host of the backend to cache (default:localhost)BACKEND_PORT: port of the backend to cache (default:3000)VARNISH_SIZE: size of the cache in the RAM (default:100M)BACKEND_FIRST_BYTE_TIMEOUT: first byte timeout (default:60s)CACHE_TTL: time to cache the request (default:3600s)BODY_SIZE: maximum size for the body ; if it exceeds this value, it will not be cached (default:2048KB)DISABLE_ERROR_CACHING: disable the caching of errors (default:true)DISABLE_ERROR_CACHING_TTL: time where requests should be directly sent to the backend after an error occured (default:30s)CONFIG_FILE: the name of the configuration file to use (default:default.vcl)ENABLE_LOGS: enable logs (default:true)ENABLE_PROMETHEUS_EXPORTER: enable the Prometheus exporter if set totrue(default:false).If enabled, the exporter will be available on the 9131 port.PURGE_ACL: custom ACL for the PURGE method (default:localhost) ; you can use0.0.0.0/0to allow all.CUSTOM_ARGS: custom arguments to pass to varnishd (default:'')
You can invalidate the cache entry by sending the same request with thePURGE method.
If your backend is sending axkey header, if you send aPURGE request with the samexkey header, it will invalidate all cache entries with the same tag.
This project is licensed under the MIT License.See theLICENSE file for details.
About
Varnish Docker image that also caches POST requests
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Contributors3
Uh oh!
There was an error while loading.Please reload this page.