diff options
| author | Christian Breunig <christian@breunig.cc> | 2024-12-11 21:07:28 +0100 |
|---|---|---|
| committer | Christian Breunig <christian@breunig.cc> | 2024-12-16 22:24:50 +0100 |
| commit | 2e4725cd77a33f91e091d86d94056f43dafd153d (patch) | |
| tree | 0165c80754a6dea656c915794508ca47fcf1668c /python/vyos/frrender.py | |
| parent | 55683a8406e17408021437cb35b57c48bd8b2ab1 (diff) | |
| download | veeos-1x-2e4725cd77a33f91e091d86d94056f43dafd153d.tar.gz veeos-1x-2e4725cd77a33f91e091d86d94056f43dafd153d.zip | |
frr: T6746: handle "system ip" and "system ipv6" with FRRender class
FRR 10.2 will use "[no] ip forwarding" and "[no] ipv6 forwarding" to enable or
disable IP(v6) forwarding. We no longer rely on sysctl as this was overridden
by FRR later on.
Remove code path for sysctl setting and solely rely on FRR.
Diffstat (limited to 'python/vyos/frrender.py')
| -rw-r--r-- | python/vyos/frrender.py | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/python/vyos/frrender.py b/python/vyos/frrender.py index f1bb39094..7a0b661a3 100644 --- a/python/vyos/frrender.py +++ b/python/vyos/frrender.py @@ -32,12 +32,16 @@ def debug(message): return print(message) -pim_daemon = 'pimd' - frr_protocols = ['babel', 'bfd', 'bgp', 'eigrp', 'isis', 'mpls', 'nhrp', 'openfabric', 'ospf', 'ospfv3', 'pim', 'pim6', 'rip', 'ripng', 'rpki', 'segment_routing', 'static'] +bgp_daemon = 'bgpd' +isis_daemon = 'isisd' +mgmt_daemon = 'mgmtd' +pim_daemon = 'pimd' +zebra_daemon = 'zebra' + class FRRender: def __init__(self): self._frr_conf = '/run/frr/config/frr.conf' @@ -100,6 +104,12 @@ class FRRender: if 'static' in config_dict and 'deleted' not in config_dict['static']: output += render_to_string('frr/staticd.frr.j2', config_dict['static']) output += '\n' + if 'ip' in config_dict and 'deleted' not in config_dict['ip']: + output += render_to_string('frr/zebra.route-map.frr.j2', config_dict['ip']) + output += '\n' + if 'ipv6' in config_dict and 'deleted' not in config_dict['ipv6']: + output += render_to_string('frr/zebra.route-map.frr.j2', config_dict['ipv6']) + output += '\n' return output debug('======< RENDERING CONFIG >======') |
