make admin list extensible
This commit is contained in:
parent
177c83be3d
commit
070d2bd56d
@ -5,4 +5,8 @@ masked_services:
|
||||
- systemd-logind.service
|
||||
- getty.target
|
||||
- systemd-journal-flush.service
|
||||
base_admins:
|
||||
- {dest: "/home/admin", owner: "admin", group: "admin"}
|
||||
- {dest: "/root", owner: "root", group: "root"}
|
||||
additional_admins: []
|
||||
ssh_ldap: false
|
||||
|
@ -75,6 +75,7 @@ root ALL=(ALL) ALL
|
||||
## Uncomment to allow members of group wheel to execute any command
|
||||
%wheel ALL=(ALL) ALL
|
||||
admin ALL=(ALL) NOPASSWD: ALL
|
||||
%admin ALL=(ALL) NOPASSWD: ALL
|
||||
|
||||
## Same thing without a password
|
||||
# %wheel ALL=(ALL) NOPASSWD: ALL
|
||||
|
@ -26,13 +26,14 @@
|
||||
- name: SSH Keys
|
||||
copy: src=authorized_keys dest=/home/admin/.ssh/authorized_keys
|
||||
|
||||
- set_fact:
|
||||
admins: "{{ base_admins + additional_admins }}"
|
||||
|
||||
- name: deploy dotfiles
|
||||
copy: src="{{ item[0] }}" dest="{{ item[1].dest }}/.{{ item[0] }}" owner="{{ item[1].owner }}" group="{{ item[1].group }}"
|
||||
with_nested:
|
||||
- ['bashrc', 'dircolors', 'vimrc']
|
||||
-
|
||||
- {dest: "/home/admin", owner: "admin", group: "admin"}
|
||||
- {dest: "/root", owner: "root", group: "root"}
|
||||
- admins
|
||||
|
||||
- mount: name=/run/systemd/journal/ src=/mnt/journal fstype=none opts=bind,ro state=present
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user