Implemented base + moved plugins & service conf

In this changeset, I implemented the main logic although this is
mainly a shameful copy/paste of Nova's blueprint
https://blueprints.launchpad.net/nova/+spec/centralize-config-options

Partially Implements: blueprint centralise-config-opts

Change-Id: Ib645ad5da5c706336bb6ac37e85b027d05665c32
This commit is contained in:
Vincent Françoise
2016-11-10 16:16:55 +01:00
parent 822fe78675
commit 46f511a8c8
18 changed files with 263 additions and 78 deletions

View File

@@ -35,7 +35,7 @@ from sqlalchemy import UniqueConstraint
from watcher.common import paths
sql_opts = [
SQL_OPTS = [
cfg.StrOpt('mysql_engine',
default='InnoDB',
help='MySQL engine to use.')
@@ -44,7 +44,7 @@ sql_opts = [
_DEFAULT_SQL_CONNECTION = 'sqlite:///{0}'.format(
paths.state_path_def('watcher.sqlite'))
cfg.CONF.register_opts(sql_opts, 'database')
cfg.CONF.register_opts(SQL_OPTS, 'database')
db_options.set_defaults(cfg.CONF, _DEFAULT_SQL_CONNECTION, 'watcher.sqlite')