Publishing the map
The map is a static site. It is built on a machine that has the data (a full build needs hours of network access and is never run in CI), packaged, attached to a release, and deployed to GitHub Pages by a workflow.
pipeline.py rebuild -> package_map.py -> release asset -> "publish map" workflow -> GitHub PagesOne-time setup
Section titled “One-time setup”- Pages needs a public repository on a free plan. Both repositories are public, so Pages is available. (GitHub Pages is not available for private repositories on the free plan.)
- Pages is enabled with GitHub Actions as the source (Settings, Pages, Build and deployment). The site is at https://maps.straatwijsheid.nl/ (custom domain, a CNAME to
straatwijsheid.github.io; the github.io address redirects to it). - Custom domain:
maps.straatwijsheid.nl, set under Settings, Pages, Custom domain, with a CNAME record tostraatwijsheid.github.io. The map uses relative paths and works at the root of a domain as well as under/straatwijsheid/.
Each publication
Section titled “Each publication”.venv/bin/python src/pipeline.py rebuild # the map and its data in build/output/.venv/bin/python src/package_map.py # build/dist/straatwijsheid-map.zip (and the unzipped site, build/dist/site/)gh release create v0.1 build/dist/straatwijsheid-map.zip --title "v0.1" --notes "..." # or: gh release upload TAG build/dist/straatwijsheid-map.zip --clobbergh workflow run "publish map" -f tag=v0.1 # empty tag: the latest release.venv/bin/python src/review_sheet.py --export build/dist/review-inputs.json.gz # what the review sheets are made fromgh release upload v0.1 build/dist/review-inputs.json.gz # then run "regenerate sheets" in the knowledge repository (Actions) for the new sheetsThe workflow downloads straatwijsheid-map.zip from the release, checks it contains index.html and data/, and deploys it. The page reports where it came from in its footer (code commit, knowledge commit, OpenStreetMap snapshot dates).
To look at the packaged site before publishing: python3 -m http.server --directory build/dist 8772 and open http://localhost:8772/site/.
What is in the package
Section titled “What is in the package”index.html (the map), data/ (per-gemeente data, the buurt polygons and the search index, each as plain .js and pre-gzipped .js.gz), PROVENANCE.json, .nojekyll. Not the CSVs or the reports: they are separate downloads.
Before the map is public
Section titled “Before the map is public”- The basemap is OpenStreetMap’s public tile server, used under its tile usage policy; NOTICE.md says how we meet it. The map must keep: the HTTPS tile URL, the visible credit “© OpenStreetMap contributors” linked to the copyright page, no prefetching or offline copies, and no restrictive referrer policy (browsers send their own User-Agent and Referer). The server is best-effort with no guarantee, and access can be withdrawn; if the site grows a real audience, switch provider or serve our own tiles by changing
tile_urlandtile_attribution(config.local.tomlorTILE_URL/TILE_ATTRIBUTION), no code change. - NOTICE.md must be accurate.
Synced from straatwijsheid/docs/publishing.md at aebc7b6. To change this page, edit it there.