]> git.koha-community.org Git - koha.git/commit
Bug 10411: add cache control headers for static resources (Debian package)
authorRobin Sheat <robin@catalyst.net.nz>
Wed, 5 Jun 2013 05:50:29 +0000 (17:50 +1200)
committerChris Hall <followingthepath@gmail.com>
Tue, 20 Aug 2013 09:03:52 +0000 (21:03 +1200)
commitea007b48e06a42fa699645993a63256ef8e7dbd4
treef291b52d3a517b703234c8fceaa45df7068c9d0b
parent1324646ff7bc9a1ae03db0baea9cb45e51f730cc
Bug 10411: add cache control headers for static resources (Debian package)

This adds caching directives to the static resources so that the browser
doesn't ask about them all the time.

By default, Debian apache doesn't have the required module (mod_expires)
enabled, and so this patch will have no effect. In order to enable this
function, run:

a2enmod expires

and restart apache.

Test Plan:
* Using firebug or equivalent, load a page.
* Note that none of the images, css, or js files have a Cache-Control or
  Expires header set.
* Add this patch, redeploy the package with it (or overwrite the
  apache-share.conf file) enable the 'expires' module, restart apache.
* Force-reload the page
* Note that the images, css, js now have Cache-Control and Expires set
  for 12 hours into the future.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit be905428722522f1ace4e99d13ffcb5d11f65657)
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
(cherry picked from commit 6b94a9a3406f7c1b58a88b54c598ad617b84ee52)
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
(cherry picked from commit 6b94a9a3406f7c1b58a88b54c598ad617b84ee52)
Signed-off-by: Chris Hall <followingthepath@gmail.com>
(cherry picked from commit 5b93649f79e6011e316055bb48c367f829c3966f)
debian/templates/apache-shared.conf