aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ansible/roles/neomutt/tasks/main.yml23
-rw-r--r--ansible/roles/postfix/meta/main.yml4
-rw-r--r--ansible/roles/postfix/tasks/main.yml4
3 files changed, 28 insertions, 3 deletions
diff --git a/ansible/roles/neomutt/tasks/main.yml b/ansible/roles/neomutt/tasks/main.yml
new file mode 100644
index 0000000..855d17c
--- /dev/null
+++ b/ansible/roles/neomutt/tasks/main.yml
@@ -0,0 +1,23 @@
+---
+- name: Install neomutt
+ package:
+ name: neomutt
+ state: present
+ tags:
+ - role::neomutt
+
+- name: Configure neomutt folder to standard destination
+ copy:
+ content: |
+ # Ansible managed
+
+ # neomutt will user ~/Mail by default, whilst our postfix installation
+ # will deliver mail to /var/mail/$USER instead. neomutt will also figure that out,
+ # but not without prompting whether to create ~/Mail on every startup first.
+ set folder = /var/mail/$USER
+ owner: root
+ group: root
+ mode: "0o444"
+ dest: /etc/neomuttrc.d/pydis.rc
+ tags:
+ - role::neomutt
diff --git a/ansible/roles/postfix/meta/main.yml b/ansible/roles/postfix/meta/main.yml
new file mode 100644
index 0000000..addf15d
--- /dev/null
+++ b/ansible/roles/postfix/meta/main.yml
@@ -0,0 +1,4 @@
+---
+dependencies:
+ # Mail client
+ - neomutt
diff --git a/ansible/roles/postfix/tasks/main.yml b/ansible/roles/postfix/tasks/main.yml
index 3340989..b8f3a35 100644
--- a/ansible/roles/postfix/tasks/main.yml
+++ b/ansible/roles/postfix/tasks/main.yml
@@ -1,5 +1,5 @@
---
-- name: Install postfix & mail client
+- name: Install postfix & tools
package:
name:
# Postfix & routing plugins
@@ -9,8 +9,6 @@
- postsrsd
# Security and anti-spam tools
- postfix-policyd-spf-python
- # Mail clients
- - neomutt
state: present
tags:
- role::postfix