The PDF is built from docs/topology_pdf/ (HTML + Graphviz), not from TOPOLOGY_EXAMPLES.md, so the two prose copies had drifted. Resync them and correct several claims that no longer matched the code. - Add a LOCAL_ALIASES overlay section (+ diagram 6): re-home a short local TG under an owned prefix so the mesh routes the long number while local clients keep dialing the short one. Translation happens at the trunk boundary only -- clients and satellites see the short number. - Peer interest: MsgPeerTgInterest (type 129) lets a passive listener register interest without keying. The HTML still claimed the owner cannot fan a TG back until the peer transmits; corrected in the Background, the section-2 return leg, and the Properties list. - Satellite trust model: per-satellite SECRET_<id> is implemented (Reflector::resolveSatelliteSecret); drop the "future work" note. - SATELLITE_FILTER: filter entries are exact unless suffixed with "*" (TgFilter::parse), so the documented bare 2222/2224 values matched only those literal TGs. Use 2222* and document the syntax. - Zones are no longer drawn as satellites. A satellite owns no prefix and inherits its parent's identity, so a prefix-owning Zone cannot be one. Zones now hang off IT 222 as sub-trunks (REMOTE_PREFIX supports a comma-separated list), shown with a mix of owned, local-only and aliased TGs. Note that ROUTABLE_PREFIXES=* forwards unowned TGs to the uplink, where the peer drops them. - Merge the old section 3 into section 2 as a "sub-trunk star" variant -- it was the same two-domain topology with a star instead of a full mesh. Satellite becomes section 3, twin section 4. - Disable code-font ligatures: JetBrains Mono rendered SECRET_<id>= as SECRET_<id>= with the ">" swallowed by a ">=" ligature.
31 lines
1.1 KiB
Bash
Executable File
31 lines
1.1 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Build docs/TOPOLOGY_EXAMPLES.pdf from the Graphviz sources and HTML
|
|
# template under docs/topology_pdf/.
|
|
#
|
|
# Dependencies:
|
|
# - graphviz (dot, circo, neato)
|
|
# - weasyprint
|
|
#
|
|
# The Markdown source (docs/TOPOLOGY_EXAMPLES.md) is independent — this
|
|
# script does not consume it. Update both if you change the prose.
|
|
|
|
set -euo pipefail
|
|
|
|
cd "$(dirname "$0")/topology_pdf"
|
|
|
|
echo "[1/3] Rendering SVG diagrams"
|
|
circo -Tsvg 01_intl_mesh.dot -o 01_intl_mesh.svg
|
|
neato -Tsvg 02_flat_mesh.dot -o 02_flat_mesh.svg
|
|
dot -Tsvg 03_subtrunk_star.dot -o 03_subtrunk_star.svg
|
|
neato -Tsvg 04_hybrid.dot -o 04_hybrid.svg
|
|
neato -Tsvg 05_twin_pair.dot -o 05_twin_pair.svg
|
|
neato -Tsvg 06_local_alias.dot -o 06_local_alias.svg
|
|
|
|
echo "[2/3] Building PDF with WeasyPrint"
|
|
BUILD_DATE=$(date -u +"%Y-%m-%d %H:%M UTC")
|
|
sed "s|__BUILD_DATE__|$BUILD_DATE|g" topology.html > topology.rendered.html
|
|
weasyprint topology.rendered.html ../TOPOLOGY_EXAMPLES.pdf
|
|
rm topology.rendered.html
|
|
|
|
echo "[3/3] Done — wrote docs/TOPOLOGY_EXAMPLES.pdf ($(stat -c%s ../TOPOLOGY_EXAMPLES.pdf) bytes)"
|