From 7575b76d5b4ae58a5aa2f1fcf77e5364cee77a2a Mon Sep 17 00:00:00 2001 From: Lucian Petrut Date: Fri, 10 Nov 2017 19:21:32 +0200 Subject: [PATCH] Add oslo.config entry point This change will allow generating a config sample using the oslo.config generator. Generating a compute-hyperv config sample may be requested by using: oslo-config-generator --namespace compute_hyperv Closes-Bug: #1731511 Change-Id: Icc39a472cb05bfd0bcb673959b40b0d2e6e89077 --- compute_hyperv/nova/conf.py | 4 ++++ setup.cfg | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/compute_hyperv/nova/conf.py b/compute_hyperv/nova/conf.py index 8853890e..fe3909e6 100644 --- a/compute_hyperv/nova/conf.py +++ b/compute_hyperv/nova/conf.py @@ -56,3 +56,7 @@ hyperv_opts = [ CONF = nova.conf.CONF CONF.register_opts(hyperv_opts, 'hyperv') + + +def list_opts(): + return [('hyperv', hyperv_opts)] diff --git a/setup.cfg b/setup.cfg index 597b903a..35d01e51 100644 --- a/setup.cfg +++ b/setup.cfg @@ -27,6 +27,10 @@ packages = nova nova.virt.compute_hyperv +[entry_points] +oslo.config.opts = + compute_hyperv = compute_hyperv.nova.conf:list_opts + [build_sphinx] source-dir = doc/source build-dir = doc/build