]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/nominatim/templates/default/updater.erb
overpass: add munin scripts
[chef.git] / cookbooks / nominatim / templates / default / updater.erb
index 37cf8937291828771e9012f789a84cd791ee04da..d3fd0d937d62aac5838ad8cce1c36d1027ca013a 100644 (file)
@@ -37,6 +37,17 @@ do
 
     if [ -f "<%= @update_maintenance_trigger %>" ]; then
         rm <%= @update_maintenance_trigger %>
 
     if [ -f "<%= @update_maintenance_trigger %>" ]; then
         rm <%= @update_maintenance_trigger %>
-        ./nominatim refresh --postcodes
+        ./nominatim refresh --postcodes --threads 4 -v
+<% if node[:nominatim][:enable_qa_tiles] -%>
+        pushd <%= @qabindir %>
+        if python3 cli.py --execute-all; then
+          rm -rf "<%= @qadatadir %>/old"
+          if [ -d "<%= @qadatadir %>/current" ]; then
+            mv "<%= @qadatadir %>/current" "<%= @qadatadir %>/old"
+          fi
+          mv "<%= @qadatadir %>/new" "<%= @qadatadir %>/current"
+        fi
+        popd
+<% end -%>
     fi
 done
     fi
 done