From 7d4fe344af75996cf94c0e1342263e4712261274 Mon Sep 17 00:00:00 2001 From: William Young Date: Fri, 17 Feb 2023 07:02:54 -0600 Subject: [PATCH] Add setup auth playbook --- setup_auth.yaml | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 setup_auth.yaml diff --git a/setup_auth.yaml b/setup_auth.yaml new file mode 100644 index 0000000..8f858a6 --- /dev/null +++ b/setup_auth.yaml @@ -0,0 +1,12 @@ +- hosts: all + tasks: + - name: Add public key to authorized_keys + authorized_key: + user: root + key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIArcvGwvT6CbzyY513rhD6zTPXxOvHEsekE5ElGc3PWv ansible@ansible.william.zone + state: present + become: true + + - name: Remove root password + shell: passwd -d root + become: true