Auto-generate Vitrage config options

Change-Id: I44704211bef51d8269a5edcf30b57a2c06638262
This commit is contained in:
Ifat Afek 2017-08-06 19:01:22 +03:00
parent 01297e9288
commit fa1db5ecc5
4 changed files with 39 additions and 3 deletions

1
.gitignore vendored
View File

@ -24,6 +24,7 @@ ChangeLog
.coverage
cover
etc/vitrage/vitrage.conf
doc/source/_static/
#Python
*.pyc

View File

@ -15,7 +15,12 @@
import os
import sys
sys.path.insert(0, os.path.abspath('../..'))
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
ROOT = os.path.abspath(os.path.join(BASE_DIR, "..", ".."))
sys.path.insert(0, ROOT)
sys.path.insert(0, BASE_DIR)
# -- General configuration ----------------------------------------------------
# Add any Sphinx extension module names here, as strings. They can be
@ -23,9 +28,14 @@ sys.path.insert(0, os.path.abspath('../..'))
extensions = [
'sphinx.ext.autodoc',
# 'sphinx.ext.intersphinx',
'openstackdocstheme'
'openstackdocstheme',
'oslo_config.sphinxconfiggen',
]
config_generator_config_file = os.path.join(ROOT,
'etc/vitrage/vitrage-config-generator.conf')
sample_config_basename = '_static/vitrage'
# autodoc generation is a bit aggressive and a nuisance when doing heavy
# text edit cycles.
# execute "export SPHINX_DEBUG=1" in your terminal to disable
@ -56,7 +66,7 @@ pygments_style = 'sphinx'
# Sphinx are currently 'default' and 'sphinxdoc'.
# html_theme_path = ["."]
# html_theme = '_theme'
# html_static_path = ['static']
html_static_path = ['_static']
html_theme = 'openstackdocs'
# openstackdocstheme options

View File

@ -0,0 +1,24 @@
.. _configuring:
=============================
Vitrage Configuration Options
=============================
Vitrage Sample Configuration File
=================================
Configure Vitrage by editing /etc/vitrage/vitrage.conf.
No config file is provided with the source code, it will be created during the
installation. In case where no configuration file was installed, one can be
easily created by running::
oslo-config-generator \
--config-file=/etc/vitrage/vitrage-config-generator.conf \
--output-file=/etc/vitrage/vitrage.conf
The following is a sample Vitrage configuration for adaptation and use. It is
auto-generated from Vitrage when this documentation is built, and can also be
viewed in `file form <../_static/vitrage.conf.sample>`_.
.. literalinclude:: ../_static/vitrage.conf.sample

View File

@ -13,6 +13,7 @@ General
profiler-config
keycloak-config
../configuration/index
Datasources
-----------