]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/taginfo/templates/default/update-taginfo.erb
Disable CacheStaleOnError for taginfo
[chef.git] / cookbooks / taginfo / templates / default / update-taginfo.erb
index 801591927356f49ebe9fa4e2154c1c151953fa6f..417c30b8614918775ed2eee6c081c5d0e96565ff 100644 (file)
@@ -6,6 +6,8 @@ set -e
 
 ROOT="<%= @directory %>"
 
+cd $ROOT/taginfo/sources
+
 if [ -f "$ROOT/data/taginfo-history.db" ]
 then
     cp $ROOT/data/taginfo-history.db $ROOT/sources
@@ -18,3 +20,5 @@ mv $ROOT/sources/taginfo-*.db $ROOT/sources/*/taginfo-*.db $ROOT/data
 mv $ROOT/sources/download/* $ROOT/download
 
 touch $ROOT/taginfo/web/tmp/restart.txt
+
+find $ROOT/sources/log -mtime +28 -delete