Remove duplicated pillar.get calls to retrieve the sshd_config and ssh_config pillars

This commit is contained in:
Meng Chen authored and alxwr committed 2019-05-25 01:52:33 +02:00
1 parent 463ad69d92
commit 3e01ad816a
4 files changed
+14 -16

No files matched your search

+3 -3
View File
@@ -1,9 +1,9 @@
{% from "openssh/map.jinja" import openssh with context %}
{% from "openssh/map.jinja" import openssh, sshd_config with context %}
include:
- openssh
{% if salt['pillar.get']('sshd_config', False) %}
{% if sshd_config %}
sshd_config-with-ini:
ini.options_present:
- name: {{ openssh.sshd_config }}
@@ -11,7 +11,7 @@ sshd_config-with-ini:
- watch_in:
- service: {{ openssh.service }}
- sections:
{%- for k,v in salt['pillar.get']('sshd_config',{}).items() %}
{%- for k,v in sshd_config.items() %}
{{ k }}: '{{ v }}'
{%- endfor %}
{% endif %}