EvoBSD/roles/base/tasks/sudo.yml

25 lines
598 B
YAML
Raw Normal View History

2018-12-28 11:23:49 +01:00
---
# dont't break the tab!
- name: Allow wheel group to run command as root in sudo
lineinfile:
dest: /etc/sudoers
insertafter: '# and set environment variables.'
line: '%wheel ALL=(ALL) SETENV: ALL'
2018-12-28 11:23:49 +01:00
validate: 'visudo -cf %s'
backup: false
2018-12-28 11:23:49 +01:00
tags:
- sudo
2018-12-28 11:23:49 +01:00
- name: Configure sudoers for evomaintenance and monitoring
blockinfile:
state: present
dest: /etc/sudoers
insertafter: EOF
block: |
Cmnd_Alias MAINT = /usr/share/scripts/evomaintenance.sh
%wheel ALL=NOPASSWD: MAINT
validate: 'visudo -cf %s'
backup: false
2018-12-28 11:23:49 +01:00
tags:
- sudo