Add basemap tile storage: Bicep infra and GPKG extraction script#4
Open
Copilot wants to merge 3 commits into
Open
Add basemap tile storage: Bicep infra and GPKG extraction script#4Copilot wants to merge 3 commits into
Copilot wants to merge 3 commits into
Conversation
Copilot created this pull request from a session on behalf of
Yeetii
April 8, 2026 09:36
View session
Agent-Logs-Url: https://github.com/Yeetii/strava/sessions/e9694873-8473-43f6-85ea-06e5aaf285de Co-authored-by: Yeetii <10732637+Yeetii@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Yeetii/strava/sessions/e9694873-8473-43f6-85ea-06e5aaf285de Co-authored-by: Yeetii <10732637+Yeetii@users.noreply.github.com>
9cfcf44 to
71c18e1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Serve Lantmäteriet topowebb raster tiles directly to MapLibre from Azure Blob Storage — no Azure Function proxy needed. Tiles are extracted once from a GeoPackage and stored at
{z}/{x}/{y}paths with public anonymous read access.infra/basemap.bicepallowBlobPublicAccess: trueGET/HEAD/OPTIONSfrom any origin, 24h max-agebasemap-tilescontainer withpublicAccess: BlobtilesBaseUrlfor direct use in MapLibre configBackend/Scripts/extract-gpkg-tiles.pyOne-time population script (pure
sqlite3, no GDAL):(zoom_level, tile_column, tile_row, tile_data)from the GPKG tile tableosm_y = (2^z - 1) - gpkg_tile_rowContent-Typefrom magic bytes (PNG/JPEG/WebP); setsCache-Control: public, max-age=86400--overwritepython extract-gpkg-tiles.py \ --gpkg topowebb.gpkg \ --connection-string "DefaultEndpointsProtocol=https;AccountName=...;..." \ --zoom 0,1,2,3,4,5,6,7,8,9,10,11,12MapLibre tile source:
{ "type": "raster", "tiles": ["https://<account>.blob.core.windows.net/basemap-tiles/{z}/{x}/{y}"], "tileSize": 256 }