From: Tom Hughes Date: Mon, 4 Jun 2018 07:29:29 +0000 (+0100) Subject: Redirect http://tile.osm.org to https://tile.openstreetmap.org X-Git-Url: https://git.openstreetmap.org./chef.git/commitdiff_plain/f24262ba0e7b60e922c8e2c56a8b77437fee8de2 Redirect http://tile.osm.org to https://tile.openstreetmap.org --- diff --git a/cookbooks/tilecache/templates/default/nginx_tile.conf.erb b/cookbooks/tilecache/templates/default/nginx_tile.conf.erb index 149ddd001..ce2b23b9a 100644 --- a/cookbooks/tilecache/templates/default/nginx_tile.conf.erb +++ b/cookbooks/tilecache/templates/default/nginx_tile.conf.erb @@ -104,3 +104,10 @@ server { server_name _; return 301 https://$host$request_uri; } + +server { + listen 80; + listen [::]:80; + server_name ~^(?(?:[a-d]\.)?tile)\.osm\.org$; + return 301 https://$subdomain.openstreetmap.org$request_uri; +}