0
0
mirror of https://github.com/saltstack-formulas/openssh-formula.git synced 2024-12-18 13:12:34 +01:00
openssh-formula/openssh/known_hosts.sls

22 lines
646 B
Plaintext
Raw Normal View History

{%- set tplroot = tpldir.split('/')[0] %}
{%- from tplroot ~ "/map.jinja" import openssh with context %}
{%- from tplroot ~ "/libtofs.jinja" import files_switch %}
ensure dig is available:
pkg.installed:
- name: {{ openssh.dig_pkg }}
2016-07-19 22:23:48 +02:00
- unless: which dig
manage ssh_known_hosts file:
file.managed:
- name: {{ openssh.ssh_known_hosts }}
- source: {{ files_switch( [openssh.ssh_known_hosts_src],
'manage ssh_known_hosts file'
) }}
- template: jinja
- user: root
- group: {{ openssh.ssh_config_group }}
- mode: 644
- require:
- pkg: ensure dig is available