1
0
Fork 0

create /etc/sudoers.d dir

- make sure that /etc/sudoers.d/* files are created after the dir
This commit is contained in:
Theo Chatzimichos 2016-04-04 13:13:15 +02:00
parent 93883cdcb6
commit 9100e2ed7a
2 changed files with 9 additions and 0 deletions

View File

@ -19,4 +19,5 @@ include:
sudoers: {{ spec|json }}
- require:
- file: {{ sudoers.get('config-path', '/etc') }}/sudoers
- file: {{ sudoers.get('config-path', '/etc') }}/sudoers.d
{% endfor %}

View File

@ -4,6 +4,14 @@ sudo:
pkg.installed:
- name: {{ sudoers.pkg }}
{{ sudoers.get('config-path', '/etc') }}/sudoers.d:
file.directory:
- user: root
- group: {{ sudoers.get('group', 'root') }}
- mode: 750
- require:
- pkg: sudo
{{ sudoers.get('config-path', '/etc') }}/sudoers:
file.managed:
- user: root