2 mkdir -p /srv/tilecache/data/$(date --utc "+%Y/%m")
3 <% @caches.each do |cache| -%>
4 <% if cache[:hostname] != node[:hostname] -%>
5 <% cache.ipaddresses(:family => :inet, :role => :external).sort.each do |address| -%>
6 curl -w "@/srv/tilecache/tilecache-curl-time.txt" -o /dev/null -s -k -4 \
7 'https://<%= cache[:hostname] %>/19/262106/174485.png' \
8 -H 'authority: c.tile.openstreetmap.org' \
9 -H 'sec-fetch-dest: image' \
10 -H 'user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36' \
12 -H 'accept: image/webp,image/apng,image/*,*/*;q=0.8' \
13 -H 'sec-fetch-site: same-site' \
14 -H 'sec-fetch-mode: no-cors' \
15 -H 'referer: https://www.openstreetmap.org/' \
16 -H 'accept-language: en-GB,en-US;q=0.9,en;q=0.8' \
17 --compressed | tee -a /srv/tilecache/data/$(date --utc "+%Y/%m")/tilecache-<%= cache[:hostname] %>-$(date --utc --iso-8601).txt
21 <% @renders.each do |render| -%>
22 <% if render[:hostname] != node[:hostname] -%>
23 <% render.ipaddresses(:family => :inet, :role => :external).sort.each do |address| -%>
24 curl -w "@/srv/tilecache/tilecache-curl-time.txt" -o /dev/null -s -k -4 \
25 'https://<%= render[:hostname] %>/19/262106/174485.png' \
26 -H 'authority: c.tile.openstreetmap.org' \
27 -H 'sec-fetch-dest: image' \
28 -H 'user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.149 Safari/537.36' \
30 -H 'accept: image/webp,image/apng,image/*,*/*;q=0.8' \
31 -H 'sec-fetch-site: same-site' \
32 -H 'sec-fetch-mode: no-cors' \
33 -H 'referer: https://www.openstreetmap.org/' \
34 -H 'accept-language: en-GB,en-US;q=0.9,en;q=0.8' \
35 --compressed | tee -a /srv/tilecache/data/$(date --utc "+%Y/%m")/render-<%= render[:hostname] %>-$(date --utc --iso-8601).txt