Merge "Add 'url' section to config, pass it down to Dockerfile.j2"

This commit is contained in:
Jenkins 2016-11-01 13:13:03 +00:00 committed by Gerrit Code Review
commit 54c3f3a4c8
3 changed files with 17 additions and 2 deletions

View File

@ -341,6 +341,7 @@ def _get_config():
CONF.registry.address, cfg['render']['namespace'])
cfg['render'].update(CONF.versions._items())
cfg['render']['url'] = CONF.url
cfg['sources'] = CONF.sources
return cfg

View File

@ -12,6 +12,7 @@ from fuel_ccp.config import registry
from fuel_ccp.config import replicas
from fuel_ccp.config import repositories
from fuel_ccp.config import sources
from fuel_ccp.config import url
LOG = logging.getLogger(__name__)
@ -54,7 +55,7 @@ CONF = _Wrapper()
CONFIG_MODULES = [
builder, cli, images, kubernetes, registry, replicas, repositories,
sources,
sources, url,
]
@ -103,7 +104,8 @@ def validate_config(yconf=None):
def load_component_defaults():
from fuel_ccp.common import utils
sections = ['versions', 'sources', 'configs', 'nodes', 'roles', 'replicas']
sections = ['versions', 'sources', 'configs', 'nodes', 'roles', 'replicas',
'url']
new_config = _yaml.AttrDict((k, _yaml.AttrDict()) for k in sections)
for path in utils.get_config_paths():
if not os.path.exists(path):

12
fuel_ccp/config/url.py Normal file
View File

@ -0,0 +1,12 @@
SCHEMA = {
'url': {
'type': 'object',
'additionalProperties': {
'type': 'string',
},
}
}
DEFAULTS = {
'url': {},
}