30 lines
866 B
YAML
30 lines
866 B
YAML
- name: create users
|
|
user:
|
|
name: "{{ item }}"
|
|
# password is dovecotpostfix
|
|
# This hash was generated with the following command:
|
|
# python3 -c "import crypt; import getpass; print(crypt.crypt(getpass.getpass()))"
|
|
password: $6$StYWEDOVhv1TnjaM$xq9mmGWY8VDGNGavODuVbCYs56keLivi9GUB3W.NCTNusQaFZsYllSVwCMGXef0.P3vlHL.GsHuD1LCngv2G7/
|
|
shell: /bin/bash
|
|
loop: "{{ local_users }}"
|
|
- name: install Mutt
|
|
apt:
|
|
name: mutt
|
|
state: present
|
|
- name: create Mutt cache directory
|
|
file:
|
|
path: "/home/{{ item }}/.mutt/cache"
|
|
state: directory
|
|
owner: "{{ item }}"
|
|
group: "{{ item }}"
|
|
loop: "{{ local_users }}"
|
|
- name: add muttrc for each user
|
|
template:
|
|
src: templates/muttrc.j2
|
|
dest: "/home/{{ item }}/.muttrc"
|
|
owner: "{{ item }}"
|
|
group: "{{ item }}"
|
|
vars:
|
|
username: "{{ item }}"
|
|
loop: "{{ local_users }}"
|