diff --git a/users/tasks/main.yml b/users/tasks/main.yml index 9cf97397..6622e6e8 100644 --- a/users/tasks/main.yml +++ b/users/tasks/main.yml @@ -29,6 +29,15 @@ - item.admin - ansible_distribution_file_variety == "Debian" + - name: Permit sudo without password + lineinfile: + path: /etc/sudoers + state: present + regexp: '^%{{ deb_users_sudoers_group }}\s' + line: '%{{ deb_users_sudoers_group }} ALL=(ALL) NOPASSWD: ALL' + when: ansible_distribution_file_variety == "Debian" + tags: [ 'users', 'sudo_wheel' ] + - name: Add the admin users to the sudoers group on rh/centos systems user: name={{ item.login }} groups={{ rh_users_sudoers_group }} append=yes with_items: '{{ users_system_users | default([]) }}'