]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/web/templates/default/logrotate.web.erb
Add logrotate where required
[chef.git] / cookbooks / web / templates / default / logrotate.web.erb
index 608fd4d38699234f2ac76e06f9cff083612f35f4..82b08c1c0f2da8b659463a15b4f4f0c5e6190093 100644 (file)
@@ -7,6 +7,7 @@
   compress
   delaycompress
   notifempty
+  su rails rails
   create 0660 rails rails
   sharedscripts
   postrotate
@@ -21,7 +22,7 @@
 <% end -%>
 <% if node[:recipes].include?("web::cgimap") -%>
     /bin/systemctl reload cgimap
-    /usr/bin/rsync --preallocate <%= node[:web][:log_directory] %>/cgimap.log.2.gz ironbelly::logs/www.openstreetmap.org/cgimap-<%= node[:hostname] %>-`date -d "-2 days" +%Y-%m-%d`.gz
+    /usr/bin/rsync --preallocate <%= node[:web][:log_directory] %>/cgimap.log.2.gz backup.openstreetmap.org::logs/www.openstreetmap.org/cgimap-<%= node[:hostname] %>-`date -d "-2 days" +%Y-%m-%d`.gz
 <% end -%>
   endscript
 }