Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: Document on how to start specific daemons with unified config in topotests #16534

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions doc/developer/topotests.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1332,6 +1332,15 @@ Example:
router.load_config(TopoRouter.RD_ZEBRA, "zebra.conf")
router.load_config(TopoRouter.RD_OSPF)

or using unified config (specifying which daemons to run is optional):

.. code:: py

for _, (rname, router) in enumerate(router_list.items(), 1):
router.load_frr_config(os.path.join(CWD, "{}/frr.conf".format(rname)), [
TopoRouter.RD_ZEBRA
TopoRouter.RD_MGMTD,
TopoRouter.RD_BGP])

- The topology definition or build function

Expand Down
4 changes: 2 additions & 2 deletions tests/topotests/lib/topotest.py
Original file line number Diff line number Diff line change
Expand Up @@ -1430,7 +1430,7 @@ def __init__(self, name, *posargs, **params):
self.daemondir = None
self.hasmpls = False
self.routertype = "frr"
self.unified_config = None
self.unified_config = False
self.daemons = {
"zebra": 0,
"ripd": 0,
Expand Down Expand Up @@ -1653,7 +1653,7 @@ def loadConf(self, daemon, source=None, param=None):
# print "Daemons before:", self.daemons
if daemon in self.daemons.keys() or daemon == "frr":
if daemon == "frr":
self.unified_config = 1
self.unified_config = True
else:
self.daemons[daemon] = 1
if param is not None:
Expand Down
Loading