]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/nominatim/templates/default/logrotate.nominatim.erb
nominatim: enable file-based query log and log rotation
[chef.git] / cookbooks / nominatim / templates / default / logrotate.nominatim.erb
index fda755c64ac3cb8b2ee06c3a590190226e1507eb..5e2caae286f9b08118dfc08611dbf28d552d86af 100644 (file)
@@ -9,3 +9,26 @@
   notifempty
   create 640 nominatim adm
 }
+
+/var/log/nominatim/query.log {
+  weekly
+  missingok
+  rotate 52
+  compress
+  delaycompress
+  notifempty
+  create 640 www-data adm
+}
+<% if node[:lsb][:release].to_f < 14.04 -%>
+
+/var/log/php5-fpm.log {
+  weekly
+  missingok
+  rotate 3
+  compress
+  delaycompress
+  postrotate
+    /usr/bin/service php5-fpm restart > /dev/null
+  endscript
+}
+<% end -%>