mirror of
https://github.com/saltstack-formulas/openssh-formula.git
synced 2026-09-25 01:41:38 +02:00
Merge pull request #51 from mathieupotier/master
Put ssh keys on configured path in sshd_config (AuthorizedKeysFile)
This commit is contained in:
+7
-1
@@ -38,12 +38,18 @@ include:
|
||||
{{ print_name(identifier, key) }}:
|
||||
ssh_auth.present:
|
||||
{{ print_ssh_auth(identifier, key) }}
|
||||
{%- if 'sshd_config' in pillar and 'AuthorizedKeysFile' in pillar['sshd_config'] %}
|
||||
- config: '{{ pillar['sshd_config']['AuthorizedKeysFile'] }}'
|
||||
{% endif -%}
|
||||
- require:
|
||||
- service: {{ openssh.service }}
|
||||
{%- else %}
|
||||
{{ print_name(identifier, key) }}:
|
||||
ssh_auth.absent:
|
||||
{{ print_ssh_auth(identifier, key) }}
|
||||
{%- if 'sshd_config' in pillar and 'AuthorizedKeysFile' in pillar['sshd_config'] %}
|
||||
- config: '{{ pillar['sshd_config']['AuthorizedKeysFile'] }}'
|
||||
{% endif -%}
|
||||
{%- endif -%}
|
||||
{%- endfor -%}
|
||||
{%- endfor -%}
|
||||
{%- endfor -%}
|
||||
Reference in New Issue
Block a user