Created
August 27, 2011 11:38
-
-
Save yalla/1175283 to your computer and use it in GitHub Desktop.
Basic memory caching for CGI-scripts in Apache2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Load modules | |
LoadModule cache_module modules/mod_cache.so | |
LoadModule mem_cache_module modules/mod_mem_cache.so | |
# Enable caching for only this script | |
CacheEnable mem /cgi-bin/bla/myscript | |
# Ignore the user's request for non-cached content | |
CacheIgnoreCacheControl On | |
# Ignore the fact that the cgi-script doesn't give the last modified header | |
CacheIgnoreNoLastMod On | |
# Cache for 5 seconds | |
CacheDefaultExpire 5 | |
# Some defaults stolen from the howto | |
MCacheSize 4096 | |
MCacheMaxObjectCount 100 | |
MCacheMinObjectSize 1 | |
MCacheMaxObjectSize 2048 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment