From eca6ae515e4ec8448ddaee3e8b2005d0fc9ea35d Mon Sep 17 00:00:00 2001 From: djpbessems Date: Mon, 14 Jun 2021 17:08:42 +0200 Subject: [PATCH] Fix Ansible loop --- .../firstboot/files/ansible_payload/roles/users/tasks/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/roles/firstboot/files/ansible_payload/roles/users/tasks/main.yml b/ansible/roles/firstboot/files/ansible_payload/roles/users/tasks/main.yml index c59cf1e..0d5da91 100644 --- a/ansible/roles/firstboot/files/ansible_payload/roles/users/tasks/main.yml +++ b/ansible/roles/firstboot/files/ansible_payload/roles/users/tasks/main.yml @@ -17,7 +17,7 @@ state: "{{ item.state }}" loop: - { regex: '$#PasswordAuthentication', line: 'PasswordAuthentication no', state: present} - - { regex: ~, line: 'PasswordAuthentication yes', state: absent} + - { regex: '$PasswordAuthentication yes', line: 'PasswordAuthentication yes', state: absent} - name: Delete 'ubuntu' user ansible.builtin.user: name: ubuntu