h5bp / server-configs-nginx

Nginx HTTP server boilerplate configs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Need to use regexp in cache_expiration.conf

markwoon opened this issue · comments

cache_expiration.conf uses $sent_http_content_type to figure out the mimetype. However, it can also include other things (e.g. text/html;charset=UTF-8) which causes the string match to fail.

It needs to use regular expressions to properly figure out the mime-type.