mirror of
https://github.com/saltstack-formulas/openssh-formula.git
synced 2026-09-22 05:46:59 +02:00
Add option to remove ssh_host_keys
This commit is contained in:
@@ -21,6 +21,15 @@ ssh_generate_host_{{ keyType }}_key:
|
||||
- creates: /etc/ssh/ssh_host_{{ keyType }}_key
|
||||
- user: root
|
||||
|
||||
{% elif salt['pillar.get']('openssh:absent_' ~ keyType ~ '_keys', False) %}
|
||||
ssh_host_{{ keyType }}_key:
|
||||
file.absent:
|
||||
- name: /etc/ssh/ssh_host_{{ keyType }}_key
|
||||
|
||||
ssh_host_{{ keyType }}_key.pub:
|
||||
file.absent:
|
||||
- name: /etc/ssh/ssh_host_{{ keyType }}_key.pub
|
||||
|
||||
{% elif salt['pillar.get']('openssh:provide_' ~ keyType ~ '_keys', False) %}
|
||||
ssh_host_{{ keyType }}_key:
|
||||
file.managed:
|
||||
|
||||
Reference in New Issue
Block a user