diff --git a/roles/iiab-admin/tasks/admin-user.yml b/roles/iiab-admin/tasks/admin-user.yml index 3a72a9272..f9c06ca26 100644 --- a/roles/iiab-admin/tasks/admin-user.yml +++ b/roles/iiab-admin/tasks/admin-user.yml @@ -33,7 +33,8 @@ # backup=yes - name: Edit the sudoers file -- first make it editable - shell: chmod 0640 /etc/sudoers + file: path=/etc/sudoers + mode=0640 - name: Have sudo log all commands it handles lineinfile: regexp=logfile @@ -52,4 +53,5 @@ dest=/etc/sudoers - name: End editing the sudoers file -- protect it again - shell: chmod 0440 /etc/sudoers + file: path=/etc/sudoers + mode=0440