Fix invalid DOT cluster label emission for host inventory
This commit is contained in:
@@ -153,10 +153,11 @@ def generate_physical_topology(compose: dict, inventory: dict, out_dot: Path, ou
|
||||
else:
|
||||
orphans.append(vm)
|
||||
for host, record in sorted(phys_names.items()):
|
||||
host_role = record.get("role", "")
|
||||
host_role = str(record.get("role", "") or "")
|
||||
cluster_label = f"{host}\\n{host_role}" if host_role else host
|
||||
lines.extend([
|
||||
f' subgraph "cluster_{host}" {{',
|
||||
f' label="{host}\\n{host_role}".strip();',
|
||||
f' label="{cluster_label}";',
|
||||
' style="rounded,filled";',
|
||||
' color="#60a5fa";',
|
||||
' fillcolor="#eff6ff";',
|
||||
|
||||
Reference in New Issue
Block a user