forked from Signum/ispmail-bookworm-ansible
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ispmail.yml
73 lines (64 loc) · 2.16 KB
/
ispmail.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
---
- hosts: all
tags: always
tasks:
- name: "Checking operating system version"
assert:
that: ansible_distribution_release == 'bookworm'
fail_msg: "This Ansible playbook is only supported on Debian Bookworm."
success_msg: "Debian Bookworm found. That makes me happy."
- hosts: all
roles:
#- dumpvars
- role: ispmail-packages
tags: packages
# Create random passwords
# - hosts: all
# tasks:
# - command: pwgen -s 25
# register: ispmail_mysql_mailserver_password
# - set_fact:
# ispmail_mysql_mailserver_password: "{{ ispmail_mysql_mailserver_password.stdout }}"
# - command: pwgen -s 25
# register: ispmail_mysql_mailadmin_password
# - set_fact:
# ispmail_mysql_mailadmin_password: "{{ ispmail_mysql_mailadmin_password.stdout }}"
# - command: pwgen -s 25
# register: ispmail_mysql_root_password
# - set_fact:
# ispmail_mysql_root_password: "{{ ispmail_mysql_root_password.stdout }}"
# - command: pwgen -s 25
# register: ispmail_mysql_roundcube_password
# - set_fact:
# ispmail_mysql_roundcube_password: "{{ ispmail_mysql_roundcube_password.stdout }}"
# - command: pwgen -s 25
# register: ispmail_rspamd_web_password
# - set_fact:
# ispmail_rspamd_web_password: "{{ ispmail_rspamd_web_password.stdout }}"
- hosts: all
roles:
- role: geerlingguy.certbot
tags: certbot
- role: ispmail-database
tags: database
- role: ispmail-postfix
tags: postfix
- role: ispmail-dovecot
tags: dovecot
- role: ispmail-webmail-apache-roundcube
tags: roundcube
- role: ispmail-rspamd
tags: rspamd
- hosts: all
# tags: always
tasks:
- debug:
msg:
- "Installation complete."
- ""
- "Web mail URL: https://{{ispmail_fqdn}}/"
- "Example email user: john@{{ispmail_domain}}"
- "Example email password: summersun"
- "Rspamd admin URL: https://{{ispmail_fqdn}}/rspamd"
- "Rspamd admin password: {{ispmail_rspamd_web_password}}"
- "DKIM public key : {{dkim_public.stdout}}"