diff options
author | Aziz Rmadi <[email protected]> | 2024-04-13 05:49:55 -0500 |
---|---|---|
committer | GitHub <[email protected]> | 2024-04-13 06:49:55 -0400 |
commit | 567d96c6245fbca6086687daa40d3f37530b4f36 (patch) | |
tree | 0625e96ec8f67aeac693017c033452d368de2813 /modules/caddyhttp/fileserver/caddyfile.go | |
parent | 5d8b45c9fbbd40c5c1a43f23a6d0c2f284d2b6ba (diff) | |
download | caddy-567d96c6245fbca6086687daa40d3f37530b4f36.tar.gz caddy-567d96c6245fbca6086687daa40d3f37530b4f36.zip |
fileserver: read etags from precomputed files (#6222)
Diffstat (limited to 'modules/caddyhttp/fileserver/caddyfile.go')
-rw-r--r-- | modules/caddyhttp/fileserver/caddyfile.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/modules/caddyhttp/fileserver/caddyfile.go b/modules/caddyhttp/fileserver/caddyfile.go index d90e4f9a0..f65695018 100644 --- a/modules/caddyhttp/fileserver/caddyfile.go +++ b/modules/caddyhttp/fileserver/caddyfile.go @@ -164,6 +164,13 @@ func (fsrv *FileServer) UnmarshalCaddyfile(d *caddyfile.Dispenser) error { } fsrv.PassThru = true + case "etag_file_extensions": + etagFileExtensions := d.RemainingArgs() + if len(etagFileExtensions) == 0 { + return d.ArgErr() + } + fsrv.EtagFileExtensions = etagFileExtensions + default: return d.Errf("unknown subdirective '%s'", d.Val()) } |