GitHub and animated gifs…
Estimated reading time: 1 mins
But that wasn’t that easy as we thought because GitHub caches images with atmos/camo and that brings in some problems with bigger gif’s…
So we had to disable image caching via the http headers of our source image but these images are located in our WordPress media library and we didn’t want to disable image caching in general.
The solution for us was to configure the serving webserver (in our case Apache) to set some caching/expiry headers via LocationMatch directive and a fancy regex. Our regex includes all pictures with the filename prefix “nocache_” - so every other image uploaded isn’t touched in any way.
Apache configuration sample
Posted on: Tue, 25 Apr 2017 16:46:47 +0100 by Unknown