I'm not entirely sure if this indicates a bug or perhaps just a documentation hole of some sort, but the behavior was unanticipated and took me a little bit to figure out. I've been playing around with some of the caching settings locally, and incrementally pushing parts to a test server. I noticed today some cached & gzipped CSS assets being served with text/html content-type on the remote test server and text/css locally (they run slightly different configs by necessity)
The assets are added to the cache with load-file-in-cache-gzip and served on the route route = ^/static/(.*)$ cache:key=static/$1,name=static_gzip,mime=1,content_encoding=gzip,no_offload=true
The unexpected behavior is that setting static-cache-paths causes mime-types to be identified without mime-file being set.
I'm not entirely sure if this indicates a bug or perhaps just a documentation hole of some sort, but the behavior was unanticipated and took me a little bit to figure out. I've been playing around with some of the caching settings locally, and incrementally pushing parts to a test server. I noticed today some cached & gzipped CSS assets being served with text/html content-type on the remote test server and text/css locally (they run slightly different configs by necessity)
The assets are added to the cache with
load-file-in-cache-gzip
and served on the routeroute = ^/static/(.*)$ cache:key=static/$1,name=static_gzip,mime=1,content_encoding=gzip,no_offload=true
The unexpected behavior is that setting
static-cache-paths
causes mime-types to be identified withoutmime-file
being set.