fix(map): serve terrain tiles from website containers too (nginx location + volume)

This commit is contained in:
gadgethd
2026-08-27 23:47:37 +00:00
parent 1888c2863c
commit c63f638d46
2 changed files with 13 additions and 0 deletions
+4
View File
@@ -464,6 +464,8 @@ services:
depends_on:
backend:
condition: service_healthy
volumes:
- ${TERRAIN_TILES_PATH:-./terrain-tiles}:/terrain-tiles:ro
tmpfs:
- /tmp:rw,noexec,nosuid,size=16m,mode=1777
- /var/cache/nginx:rw,noexec,nosuid,size=32m,uid=101,gid=101,mode=0755
@@ -596,6 +598,8 @@ services:
depends_on:
backend:
condition: service_healthy
volumes:
- ${TERRAIN_TILES_PATH:-./terrain-tiles}:/terrain-tiles:ro
tmpfs:
- /tmp:rw,noexec,nosuid,size=16m,mode=1777
- /var/cache/nginx:rw,noexec,nosuid,size=32m,uid=101,gid=101,mode=0755
+9
View File
@@ -85,6 +85,15 @@ server {
try_files $uri =404;
}
# OS Terrain 50 terrain tiles (terrarium-encoded PNG)
location /terrain-tiles/ {
alias /terrain-tiles/;
include /etc/nginx/snippets/security-headers.conf;
add_header Access-Control-Allow-Origin *;
add_header Cache-Control "public, max-age=604800, immutable";
try_files $uri =404;
}
# Prefer the prerendered route shell (for example /topology/index.html)
# without redirecting the public URL to this container's internal port.
location / {