# For downloadable regional vector tilesets location ~ ^/maps { rewrite ^/maps(.*)$ /osm-vector-maps/viewer$1; } location ~ ^/osm-vector-maps(.*)\.php(.*)$ { alias /library/www/osm-vector-maps$1.php$2; # /library/www/osm-vector-maps proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $remote_addr; proxy_set_header Host $host; fastcgi_pass php; fastcgi_index index.html; include fastcgi_params; fastcgi_split_path_info ^(.+\.php)(.*)$; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param SCRIPT_NAME $fastcgi_script_name; fastcgi_param PATH_INFO $2; } location ~ ^/osm-vector-maps/ { root /library/www; }