X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/e04d5293a6521fd69d82cb122b04c0ee3e549ee4..20470a64f04ff1fc122fc5b214c9fc44b364bcee:/cookbooks/nominatim/recipes/default.rb?ds=sidebyside diff --git a/cookbooks/nominatim/recipes/default.rb b/cookbooks/nominatim/recipes/default.rb index 845bb7700..6f3394403 100644 --- a/cookbooks/nominatim/recipes/default.rb +++ b/cookbooks/nominatim/recipes/default.rb @@ -54,7 +54,7 @@ node[:nominatim][:fpm_pools].each do |name,data| group "root" mode 0644 variables data.merge(:name => name) - notifies :reload, resources(:service => "php5-fpm") + notifies :reload, "service[php5-fpm]" end end @@ -93,6 +93,14 @@ directory "/var/log/nominatim" do mode 0755 end +template "/etc/logrotate.d/nominatim" do + source "logrotate.nominatim.erb" + owner "root" + group "root" + mode 0644 +end + + package "osmosis" package "gcc" package "proj-bin" @@ -243,3 +251,19 @@ end munin_plugin "nominatim_throttled_ips" do target "#{source_directory}/munin/nominatim_throttled_ips" end + +template "/usr/local/bin/backup-nominatim" do + source "backup-nominatim.erb" + owner "root" + group "root" + mode 0755 +end + +cron "nominatim_backup" do + hour "3" + minute "00" + day "1" + command "/usr/local/bin/backup-nominatim" + user "nominatim" + mailto email_errors +end