Add list_opts() function and define entry point

This patch makes it possible to use oslo-config-generator, which was not
possible without the correct oslo.config entry point.

Change-Id: I5174fb7a8e10b2f8a833bca5c54b4d05b0e91ad0
This commit is contained in:
Thomas Goirand 2022-11-02 14:49:21 +01:00
parent da38db5ea6
commit fb1d984b42
2 changed files with 10 additions and 0 deletions

View File

@ -140,3 +140,10 @@ def get_root_helper(conf):
def setup_privsep():
priv_context.init(root_helper=shlex.split(get_root_helper(cfg.CONF)))
def list_opts():
return [
("DEFAULT", agent_opts),
("AGENT", root_helper_opts)
]

View File

@ -37,3 +37,6 @@ console_scripts =
ovn_bgp_agent.drivers =
ovn_bgp_driver = ovn_bgp_agent.drivers.openstack.ovn_bgp_driver:OVNBGPDriver
ovn_evpn_driver = ovn_bgp_agent.drivers.openstack.ovn_evpn_driver:OVNEVPNDriver
oslo.config.opts =
ovnbgpagent = ovn_bgp_agent.config:list_opts