add configuration files and options
Implements: blueprint get-topology-api Change-Id: Id0399997cfe23975774a828cbc6e608484f0b988
This commit is contained in:
parent
6d0c510360
commit
cb4e3be14e
1
.gitignore
vendored
1
.gitignore
vendored
@ -21,6 +21,7 @@ ChangeLog
|
||||
.testrepository
|
||||
.coverage
|
||||
cover
|
||||
etc/vitrage/vitrage.conf
|
||||
|
||||
#Python
|
||||
*.pyc
|
||||
|
4
etc/vitrage/README-vitrage.conf.txt
Normal file
4
etc/vitrage/README-vitrage.conf.txt
Normal file
@ -0,0 +1,4 @@
|
||||
To generate the sample vitrage.conf file, run the following
|
||||
command from the top-level vitrage directory:
|
||||
|
||||
tox -egenconfig
|
14
etc/vitrage/api-paste.ini
Normal file
14
etc/vitrage/api-paste.ini
Normal file
@ -0,0 +1,14 @@
|
||||
# Remove keystone_authtoken from the pipeline if you don't want to use keystone authentication
|
||||
[pipeline:main]
|
||||
pipeline = keystone_authtoken vitrage
|
||||
|
||||
[app:vitrage]
|
||||
paste.app_factory = vitrage.api.app:app_factory
|
||||
|
||||
[filter:keystone_authtoken]
|
||||
paste.filter_factory = keystonemiddleware.auth_token:filter_factory
|
||||
oslo_config_project = vitrage
|
||||
|
||||
[filter:cors]
|
||||
paste.filter_factory = oslo_middleware.cors:filter_factory
|
||||
oslo_config_project = vitrage
|
9
etc/vitrage/vitrage-config-generator.conf
Normal file
9
etc/vitrage/vitrage-config-generator.conf
Normal file
@ -0,0 +1,9 @@
|
||||
[DEFAULT]
|
||||
output_file = etc/vitrage/vitrage.conf
|
||||
wrap_width = 79
|
||||
namespace = vitrage
|
||||
namespace = oslo.db
|
||||
namespace = oslo.log
|
||||
namespace = oslo.middleware
|
||||
namespace = oslo.policy
|
||||
namespace = keystonemiddleware.auth_token
|
7
tox.ini
7
tox.ini
@ -9,11 +9,16 @@ install_command = pip install -U {opts} {packages}
|
||||
setenv =
|
||||
VIRTUAL_ENV={envdir}
|
||||
deps = -r{toxinidir}/test-requirements.txt
|
||||
commands = python setup.py testr --slowest --testr-args='{posargs}'
|
||||
commands =
|
||||
python setup.py testr --slowest --testr-args='{posargs}'
|
||||
oslo-config-generator --config-file=etc/vitrage/vitrage-config-generator.conf
|
||||
|
||||
[testenv:pep8]
|
||||
commands = flake8
|
||||
|
||||
[testenv:genconfig]
|
||||
commands = oslo-config-generator --config-file=etc/vitrage/vitrage-config-generator.conf
|
||||
|
||||
[testenv:venv]
|
||||
commands = {posargs}
|
||||
|
||||
|
@ -15,6 +15,17 @@ from oslo_config import cfg
|
||||
|
||||
def list_opts():
|
||||
return [("api", (
|
||||
cfg.PortOpt('port',
|
||||
default=8999,
|
||||
help='The port for the vitrage API server.',
|
||||
),
|
||||
cfg.StrOpt('host',
|
||||
default='0.0.0.0',
|
||||
help='The listen IP for the vitrage API server.',
|
||||
),
|
||||
cfg.StrOpt('paste_config', default="api-paste.ini",
|
||||
help="Configuration file for WSGI definition of API."),
|
||||
|
||||
cfg.IntOpt('workers', default=1,
|
||||
min=1,
|
||||
help='Number of workers for vitrage API server.'),
|
||||
|
Loading…
Reference in New Issue
Block a user