diff options
author | Trygve Laugstøl <trygvis@inamo.no> | 2023-11-14 14:14:44 +0100 |
---|---|---|
committer | Trygve Laugstøl <trygvis@inamo.no> | 2023-11-14 14:14:44 +0100 |
commit | 6dca28918be80a3ef0c2959a99067337f59f5972 (patch) | |
tree | e72273247504d89e0f462c7308e96a22bf17ee40 /6/bgp.pl | |
parent | de3d2c7ed173d6a3478f2432dea441a7e2e1088a (diff) | |
download | prolog-firewall-6dca28918be80a3ef0c2959a99067337f59f5972.tar.gz prolog-firewall-6dca28918be80a3ef0c2959a99067337f59f5972.tar.bz2 prolog-firewall-6dca28918be80a3ef0c2959a99067337f59f5972.tar.xz prolog-firewall-6dca28918be80a3ef0c2959a99067337f59f5972.zip |
wip
Diffstat (limited to '6/bgp.pl')
-rw-r--r-- | 6/bgp.pl | 13 |
1 files changed, 2 insertions, 11 deletions
@@ -84,15 +84,6 @@ to_dict(neighbor(_, Remote), Dict) :- host_config(Remote, RC), } }. -routers_entry(router(R), Dict) :- - D = to_dict(router(R)), - pairs_keys_values(Data, [R], [D]), - dict_create(Dict, _, Data). - -bird_config(Dict) :- +bird_config(RouterDicts) :- routers(Routers), - maplist(to_dict(), Routers, RouterDicts), -% maplist(routers_entry(), Routers, RouterDicts), - Dict = _{routers:RouterDicts}. -% findall(neighbor(H, R), (host(H), host(R), neighbor(H, R)), Routers), -% yaml_write(current_output, _{neighbors:BgpConnectionDicts}). + maplist(to_dict(), Routers, RouterDicts). |