Fix regex patterns
This commit is contained in:
parent
eca6ae515e
commit
10624f8c90
@ -16,8 +16,8 @@
|
|||||||
line: "{{ item.line }}"
|
line: "{{ item.line }}"
|
||||||
state: "{{ item.state }}"
|
state: "{{ item.state }}"
|
||||||
loop:
|
loop:
|
||||||
- { regex: '$#PasswordAuthentication', line: 'PasswordAuthentication no', state: present}
|
- { regex: '^#PasswordAuthentication', line: 'PasswordAuthentication no', state: present}
|
||||||
- { regex: '$PasswordAuthentication yes', line: 'PasswordAuthentication yes', state: absent}
|
- { regex: '^PasswordAuthentication yes', line: 'PasswordAuthentication yes', state: absent}
|
||||||
- name: Delete 'ubuntu' user
|
- name: Delete 'ubuntu' user
|
||||||
ansible.builtin.user:
|
ansible.builtin.user:
|
||||||
name: ubuntu
|
name: ubuntu
|
||||||
|
Loading…
Reference in New Issue
Block a user