Commit b6a8de2f authored by Vincent Pelletier's avatar Vincent Pelletier

erp5: Increase parameter validation.

parent 402b57f5
...@@ -296,7 +296,7 @@ extra-context = ...@@ -296,7 +296,7 @@ extra-context =
[template-erp5] [template-erp5]
< = download-base < = download-base
filename = instance-erp5.cfg.in filename = instance-erp5.cfg.in
md5sum = 345f90dcdd74eba01b22c6dd3a5719e1 md5sum = dcfc083916510848eabd73660397d741
[template-neo] [template-neo]
< = download-base < = download-base
......
...@@ -32,7 +32,7 @@ return = {{ ret.keys() | join(' ') }} ...@@ -32,7 +32,7 @@ return = {{ ret.keys() | join(' ') }}
{% do publish_dict.__setitem__(name ~ '-' ~ ret, '${' ~ section ~ ':connection-' ~ ret ~ '}')%} {% do publish_dict.__setitem__(name ~ '-' ~ ret, '${' ~ section ~ ':connection-' ~ ret ~ '}')%}
{% endif -%} {% endif -%}
{% endfor -%} {% endfor -%}
sla-computer_guid = {{ slapparameter_dict.get(config_key + '-computer-guid', computer_id) }} sla-computer_guid = {{ dumps(slapparameter_dict.get(config_key + '-computer-guid', computer_id)) }}
extra-config = {{ ' '.join(config) }} extra-config = {{ ' '.join(config) }}
{% for option, value in config.items() -%} {% for option, value in config.items() -%}
config-{{ option }} = {{ dumps(value) }} config-{{ option }} = {{ dumps(value) }}
...@@ -43,7 +43,9 @@ config-{{ option }} = {{ dumps(value) }} ...@@ -43,7 +43,9 @@ config-{{ option }} = {{ dumps(value) }}
{{ request('memcached-volatile', 'kumofs', 'memcached', {'tcpv4-port': 2010, 'ram-storage-size': 64}) }} {{ request('memcached-volatile', 'kumofs', 'memcached', {'tcpv4-port': 2010, 'ram-storage-size': 64}) }}
{{ request('cloudooo', 'cloudooo', 'cloudooo', {'tcpv4-port': 2020}) }} {{ request('cloudooo', 'cloudooo', 'cloudooo', {'tcpv4-port': 2020}) }}
{{ request('mariadb', 'mariadb', 'mariadb', {'tcpv4-port': 2099}, {'database-list': True, 'test-database-list': True}) }} {{ request('mariadb', 'mariadb', 'mariadb', {'tcpv4-port': 2099}, {'database-list': True, 'test-database-list': True}) }}
{{ request('zodb', 'zodb-' ~ slapparameter_dict.get('zodb-software-type', 'zeo'), 'zodb', {'tcpv4-port': 2100, 'zodb-dict': {'root': {}}}, {'zodb-storage-type': False, 'zodb-dict': False, 'tidstorage-ip': False, 'tidstorage-port': False}) }} {# Fail early if an unexpected value is provided -#}
{% set possible_software_type_dict = {'zeo': 'zeo', 'neo': 'neo'} -%}
{{ request('zodb', 'zodb-' ~ possible_software_type_dict[slapparameter_dict.get('zodb-software-type', 'zeo')], 'zodb', {'tcpv4-port': 2100, 'zodb-dict': {'root': {}}}, {'zodb-storage-type': False, 'zodb-dict': False, 'tidstorage-ip': False, 'tidstorage-port': False}) }}
[inituser-password] [inituser-password]
{% set inituser_password = slapparameter_dict.get('inituser-password') -%} {% set inituser_password = slapparameter_dict.get('inituser-password') -%}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment