Check for presence of 'lookup' key
Access to this key might have failed otherwise when the user specifies no pillar.
This commit is contained in:
parent
2975f9b904
commit
9d3f30efe8
|
@ -23,8 +23,8 @@ sysctl-present-{{ param_name }}:
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{## Support for legacy pillar structure ##}
|
{## Support for legacy pillar structure ##}
|
||||||
{%- if sysctl_settings.lookup.params2 is defined -%}
|
{%- if sysctl_settings.lookup is defined %}
|
||||||
|
{% if sysctl_settings.lookup.params2 is defined -%}
|
||||||
{%- for param_name, param in sysctl_settings.lookup.get('params2', {}).items() -%}
|
{%- for param_name, param in sysctl_settings.lookup.get('params2', {}).items() -%}
|
||||||
{%- if param is mapping %}
|
{%- if param is mapping %}
|
||||||
sysctl-present-{{ param_name }}:
|
sysctl-present-{{ param_name }}:
|
||||||
|
@ -50,5 +50,6 @@ sysctl-present-{{ param.name }}:
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
{% endif -%}
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
|
|
Loading…
Reference in New Issue