From 72163bd5f3ccefc1edda585f6f605c37e774a0b8 Mon Sep 17 00:00:00 2001 From: "Ondrej Zajicek (work)" Date: Tue, 9 Jan 2018 18:42:22 +0100 Subject: [PATCH] Nest: Allow modification of channels inherited from templates Multiple definitions of same channels are forbidden, but inherited channel can be redefined. In such case channel options are merged. --- doc/bird.sgml | 66 +++++++++++++++++++++++++++++++++------------ nest/config.Y | 2 +- nest/proto.c | 25 ++++++++++++++--- nest/protocol.h | 4 ++- proto/bgp/config.Y | 16 ++++++----- proto/ospf/config.Y | 7 ++--- proto/pipe/config.Y | 2 +- proto/radv/radv.c | 2 +- proto/rip/rip.c | 2 +- proto/rpki/rpki.c | 2 +- 10 files changed, 93 insertions(+), 35 deletions(-) diff --git a/doc/bird.sgml b/doc/bird.sgml index 3a2607b4..bde825c3 100644 --- a/doc/bird.sgml +++ b/doc/bird.sgml @@ -407,31 +407,33 @@ extensive way. a comment, whitespace characters are treated as a single space. If there's a variable number of options, they are grouped using the Here is an example of a simple config file. It enables synchronization of -routing tables with OS kernel, scans for new network interfaces every 10 seconds -and runs RIP on all network interfaces found. +routing tables with OS kernel, learns network interfaces and runs RIP on all +network interfaces found. protocol kernel { + ipv4 { + export all; # Default is export none + }; persist; # Don't remove routes on BIRD shutdown - scan time 20; # Scan kernel routing table every 20 seconds - export all; # Default is export none } protocol device { - scan time 10; # Scan interfaces every 10 seconds } protocol rip { - export all; - import all; + ipv4 { + import all; + export all; + }; interface "*"; } @@ -775,8 +777,10 @@ agreement").