mod_proxy + mod_expires

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I have a local cache (mod_disk_cache) of map tiles from OpenStreetMap
on my web server. My apache configuration pulls the tiles from
tile.openstreetmap.org using the following proxy settings:

ProxyPass /osmtiles/ http://tile.openstreetmap.org/
ProxyPassReverse /osmtiles/ http://tile.openstreetmap.org/

tile.openstreetmap.org sets a very short Expires header on its tiles
(1 hour). I would like to lengthen the Expires to 1 week from access
date. Theoretically I can do this with mod_expires as follows:

<Location /osmtiles>
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/png "access plus 1 week"
</IfModule>
</Location>


However,


wget -S http://newhanoian.xemzi.com/osmtiles/13/6503/3605.png
--2009-04-29 08:18:51--
http://newhanoian.test.xemzi.com/osmtiles/13/6503/3605.png
Resolving newhanoian.xemzi.com... 203.86.236.165
Connecting to newhanoian.xemzi.com|203.86.236.165|:80... connected.
HTTP request sent, awaiting response...
  HTTP/1.1 200 OK
  Date: Wed, 29 Apr 2009 01:18:51 GMT
  Server: Apache/2.2.9 (Debian) PHP/5.2.6-1+lenny2 with Suhosin-Patch
  ETag: "a55eb96fa02faf171ebad269e96dec17"
  Content-Length: 12214
  Cache-Control: max-age=3872
  Expires: Wed, 29 Apr 2009 01:56:24 GMT
  Age: 1620
  Keep-Alive: timeout=15, max=100
  Connection: Keep-Alive
  Content-Type: image/png
Length: 12214 (12K) [image/png]


I've searched a fair bit on this, and found a patch from AllAfrica.com
that adds directives to explicitly change headers on proxied content,
but I'd rather not maintain a patched apache if possible.
Other than that I found a 5-year-old bug that claims to be fixed.

Is anyone else using this combination, and successfully?

TIA,

Tom


Director of Technology - The New Hanoian
www.newhanoian.com - tom@xxxxxxxxxxxxxx
+84 904 343 601

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux