Skip to content

Commit 7dcef9c

Browse files
AlexCherrypiclaude
andcommitted
Fix Mermaid parse error in architecture diagram
GitHub's Mermaid renderer requires the graph-type declaration (`flowchart TD`) as the first non-empty line — comments before it trip the parser ("Expecting GRAPH, got NODE_STRING"). Moved all header comments inside the block, after the declaration, where they're still visible to anyone editing the source. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 7ec80f5 commit 7dcef9c

1 file changed

Lines changed: 12 additions & 11 deletions

File tree

README.md

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -168,16 +168,17 @@ invariants the code relies on — read [ARCHITECTURE.md](ARCHITECTURE.md).
168168
The sketch below is the one-screen version.
169169

170170
```mermaid
171-
%% Three roles in vertical layers:
172-
%% LAN → network-anchor (anchord) → transit-bridge
173-
%% → service-anchors (+ app containers via netns share)
174-
%% → backend-bridge → DBs
175-
%%
176-
%% Edge styles:
177-
%% solid arrow = "traffic flows here"
178-
%% thick arrow = membership in a Docker bridge
179-
%% dashed arrow = netns share via `network_mode: service:<anchor>`
180171
flowchart TD
172+
%% Three roles in vertical layers:
173+
%% LAN -> network-anchor (anchord) -> transit-bridge
174+
%% -> service-anchors (+ app containers via netns share)
175+
%% -> backend-bridge -> DBs
176+
%%
177+
%% Edge styles:
178+
%% solid arrow = traffic flow
179+
%% thick arrow = membership in a Docker bridge
180+
%% dashed arrow = netns share via network_mode:service:<anchor>
181+
181182
%% External entry: VLAN sub-interface on the host. The whole
182183
%% project gets ONE IP via DHCP on this VLAN.
183184
LAN[/"External LAN<br/>VLAN eth0.42"/]
@@ -197,15 +198,15 @@ flowchart TD
197198
Smtp["<b>smtp-anchor</b><br/>service-anchor mode<br/>(namespace owner)"]
198199
Imap["<b>imap-anchor</b><br/>service-anchor mode<br/>(namespace owner)"]
199200
200-
%% Application containers share the SA's netns,
201+
%% Application containers - share the SA's netns,
201202
%% no own IP, no own MAC. Just processes in a borrowed namespace.
202203
Postfix(("postfix"))
203204
Dovecot(("dovecot"))
204205
205206
%% Backend bridge: shared L2 for SAs to reach DBs.
206207
%% Backend services never see the transit network.
207208
Backend[("<b>backend-bridge</b><br/>Docker bridge, internal: true")]
208-
DBs[/"mysql, redis, "/]
209+
DBs[/"mysql, redis, ..."/]
209210
210211
LAN -->|"macvlan + DHCP<br/>one IP per project"| Anchord
211212
Anchord ==> Transit

0 commit comments

Comments
 (0)