forked from ISTI-ansible-roles/ansible-roles
17 lines
395 B
YAML
17 lines
395 B
YAML
|
---
|
||
|
- name: Install the ssh keys for the authorized users
|
||
|
authorized_key: user=root key="{{ item }}" state=present
|
||
|
with_items: user_ssh_key
|
||
|
tags:
|
||
|
- pubkeys
|
||
|
- ssh_keys
|
||
|
|
||
|
- name: Remove obsolete ssh keys if there are any
|
||
|
authorized_key: user=root key="{{ item }}" state=absent
|
||
|
with_items: obsolete_ssh_key
|
||
|
when: obsolete_ssh_key is defined
|
||
|
tags:
|
||
|
- pubkeys
|
||
|
- ssh_keys
|
||
|
|