Due to Nginx limitations, file extensions are not supported for gzip. It supports only specific mime types (Content-Type header returned from the origin). You could change the mime types on the origin using parameters from the list below.
We have a whitelist of mime types we automatically gzip on-demand at the edge servers. We are happy to include any mime types that are not included in this list but can be compressed further.
The mime types in the whitelist can be requested in either a gzip or non gzip format based on the headers passed. The reason why it is based on headers passed is serving compressed content without the client requesting it and risks of breaking client/browser that do not handle "Content-Encoding: gzip" properly.
Currently the whitelist is:
"gzip_min_length" defaults to 1000.
Note that origin must include "Content-Type" in response header in order for the gzip feature to work.