tlu/salt/states/ssh/init.sls
2021-11-23 11:50:34 +01:00

17 lines
334 B
Plaintext

Install sshd:
pkg.installed:
- name: openssh-server
start sshd:
service.running:
- name: sshd
- enable: True
{% if pillar['ssh']['user_pub_keys'] %}
{{ pillar['username'] }}_autherized_keys:
ssh_auth:
- present
- user: {{ pillar['username'] }}
- names: {{ pillar['ssh']['user_pub_keys'] }}
{% endif %}