mirror of
https://git.lapiole.org/dani/ansible-roles.git
synced 2025-07-27 00:05:44 +02:00
Update to 2021-12-13 23:00
This commit is contained in:
@@ -34,6 +34,7 @@ sshd_password_auth: True
|
||||
#
|
||||
|
||||
# User configuration
|
||||
ssh_users: []
|
||||
#ssh_users:
|
||||
# - name: dani
|
||||
# create_user: False
|
||||
|
@@ -56,13 +56,12 @@
|
||||
- name: Deploy ssh user keys
|
||||
authorized_key:
|
||||
user: "{{ item.name }}"
|
||||
key: "{{ item.ssh_keys| default([]) | join(\"\n\") }}"
|
||||
key: "{{ item.ssh_keys | default([]) | flatten | join(\"\n\") }}"
|
||||
key_options: "{{ item.key_options | default([]) | join(',') }}"
|
||||
path: "{{ item.keys_file | default('/etc/ssh/authorized_keys/' ~ item.name ~ '/authorized_keys') }}"
|
||||
manage_dir: False
|
||||
exclusive: True
|
||||
ignore_errors: True # Needed eg, if LDAP isn't available on first run
|
||||
#when: item.ssh_keys is defined
|
||||
loop: "{{ ssh_users }}"
|
||||
tags: ssh
|
||||
|
||||
|
Reference in New Issue
Block a user