Don't add SSH keys to root

This commit is contained in:
Sam A. 2023-03-07 22:05:01 +01:00
parent 1542b0faf0
commit 0fd11fee37
Signed by: samsapti
GPG Key ID: CBBBE7371E81C4EA
1 changed files with 0 additions and 6 deletions

View File

@ -15,9 +15,3 @@
key: "{{ item.ssh_keys | join('\n') }}"
exclusive: true
loop: "{{ users | default([]) }}"
- name: "Add ssh authorized_keys to root user"
ansible.posix.authorized_key:
user: "root"
key: "{{ users | default([]) | map(attribute='ssh_keys') | flatten | join('\n') }}"
exclusive: true