Skip to content

Provides a directive to add expires headers to certain paths

License

Notifications You must be signed in to change notification settings

epicagency/caddy-expires

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

caddy-expires

Provides a directive to add expires headers to certain paths or headers

Usage

Add an expires block to your CaddyFile

expires {
    match [a valid regexp] [1y1m1d1h1i1s]
    match_header [header name] [a valid regexp] [1y1m1d1h1i1s]
}

Duration can be any combination of y(ear), m(onth), d(ay), h(our), i(minute), s(econd). Parts can be omitted but must remain in that order

If a path or header matches, an Expires header is set (don't forget to version your assets)

License

MIT

About

Provides a directive to add expires headers to certain paths

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages