Skip to content

NGINX module to override `Last-Modified` and `ETag` response headers

Notifications You must be signed in to change notification settings

3dyd/ngx_http_last_modified_filter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 

Repository files navigation

ngx_http_last_modified_filter

NGINX module to override Last-Modified and ETag response headers using last access time of different files.

Directives

Syntax: last_modified_override on | off;
Default: last_modified_override off;
Context: server, location

Enables or disables the override of Last-Modified and ETag headers in response header fields.

Syntax: last_modified_try_files file ...;
Default:
Context: server, location

Defines files whose last access time should be considered. Last-Modified header value is retained if it contains more recent date than the files.

The path to a file is constructed from the file parameter according to the root and alias directives. Variables can be used.

Contexts are merged. I.e. if you have files in server and location contexts they all are considered.

By default nonexistent files do not lead to an error processing request. If you want internal server error to be fired if some file does not exist, prepend its path with ! character.

Syntax: last_modified_clear_etag on | off;
Default: last_modified_clear_etag on;
Context: server, location

If disabled, ETag response header will be removed.

About

NGINX module to override `Last-Modified` and `ETag` response headers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages