]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/web/templates/default/statistics.erb
Use osmosis 0.47.4 for hourly and daily replication
[chef.git] / cookbooks / web / templates / default / statistics.erb
index 175f0a9e8d712d7731cbed02923b61d9cbefd4b7..a42357ba8e2f3ac4203ad14faaac4b15819c9f9c 100644 (file)
@@ -1,7 +1,13 @@
 #!/bin/sh
 
 #!/bin/sh
 
+# Abort on error
+set -e
+
+# Make sure /usr/local/bin is on the path
+export PATH=$PATH:/usr/local/bin
+
 # Generate new statistics
 # Generate new statistics
-<%= @directory %>/script/statistics > <%= @directory %>/tmp/data_stats.html
+<%= @ruby %> -W0 <%= @directory %>/script/statistics > <%= @directory %>/tmp/data_stats.html
 
 # Move new statistics into place
 mv -f <%= @directory %>/tmp/data_stats.html /store/rails/stats
 
 # Move new statistics into place
 mv -f <%= @directory %>/tmp/data_stats.html /store/rails/stats