diff --git a/defaults/main.yml b/defaults/main.yml index 2c0ad8d..b55661e 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -20,6 +20,19 @@ mailman_memcache_hosts: '127.0.0.1:11211' mailman_site_url: 'http://localhost' mailman_logrotate_freq: 'weekly' mailman_logrotate_retain: 10 +mailman_custom_templates: + - 'en/list:admin:action:post.txt' + - 'en/list:member:digest:masthead.txt' + - 'en/list:member:generic:footer.txt' + - 'en/list:user:notice:post.txt' + - 'en/list:user:notice:probe.txt' + - 'en/list:user:notice:welcome.txt' + - 'it/list:admin:action:post.txt' + - 'it/list:member:digest:masthead.txt' + - 'it/list:member:generic:footer.txt' + - 'it/list:user:notice:post.txt' + - 'it/list:user:notice:probe.txt' + - 'it/list:user:notice:welcome.txt' # Documentation that must be followed to configure the social auth providers # https://django-allauth.readthedocs.io/en/latest/installation.html diff --git a/tasks/mailman.yml b/tasks/mailman.yml index a5ee6a3..1cdc55a 100644 --- a/tasks/mailman.yml +++ b/tasks/mailman.yml @@ -132,3 +132,17 @@ state: present tags: [ 'mailman', 'mailman_conf', 'mailman_cron' ] + +- name: Install some default templates + block: + - name: Create the 'site' directory and the language subdirs + file: dest={{ mailman_var_dir }}/templates/site/{{ item }} state=directory owner={{ mailman_user }} group={{ mailman_user}} + with_items: + - it + - en + + - name: Install the custom templates + template: src=site/{{ item }}.j2 dest={{ mailman_var_dir }}/templates/site/{{ item }} owner={{ mailman_user }} group={{ mailman_user}} + with_items: '{{ mailman_custom_templates }}' + + tags: [ 'mailman', 'mailman_templates' ] diff --git a/templates/site/en/domain:admin:notice:new:list.txt.j2 b/templates/site/en/domain:admin:notice:new:list.txt.j2 new file mode 100644 index 0000000..c4d1efe --- /dev/null +++ b/templates/site/en/domain:admin:notice:new:list.txt.j2 @@ -0,0 +1,19 @@ +The mailing list '$listname' has just been created for you. The +following is some basic information about your mailing list. + +You can configure your mailing list at the following web page: + + {{ mailman_site_url }}postorius/lists/$list_id/ + +The web page for users of your mailing list is: + + {{ mailman_site_url }}postorius/lists/$list_id/members/member/ + +There is also an email-based interface for users (not administrators) of your +list; you can get info about using it by sending a message with just the word +'help' as subject or in the body, to: + + $request_email + +Please address all questions to $site_email. + diff --git a/templates/site/en/list:admin:action:post.txt.j2 b/templates/site/en/list:admin:action:post.txt.j2 new file mode 100644 index 0000000..e9dec96 --- /dev/null +++ b/templates/site/en/list:admin:action:post.txt.j2 @@ -0,0 +1,14 @@ +As list administrator, your authorization is requested for the +following mailing list posting: + + List: $listname + From: $sender_email + Subject: $subject + +The message is being held because: + +$reasons + +At your convenience, visit + {{ mailman_site_url }}postorius/lists/$list_id/held_messages +to approve or deny the request. diff --git a/templates/site/en/list:member:digest:masthead.txt.j2 b/templates/site/en/list:member:digest:masthead.txt.j2 new file mode 100644 index 0000000..c4f1370 --- /dev/null +++ b/templates/site/en/list:member:digest:masthead.txt.j2 @@ -0,0 +1,13 @@ +Send $display_name mailing list submissions to + $listname + +To subscribe or unsubscribe via the World Wide Web, visit + {{ mailman_site_url }}postorius/lists/$list_id/ +or, via email, send a message with subject or body 'help' to + $request_email + +You can reach the person managing the list at + $owner_email + +When replying, please edit your Subject line so it is more specific than +"Re: Contents of $display_name digest..." diff --git a/templates/site/en/list:member:generic:footer.txt.j2 b/templates/site/en/list:member:generic:footer.txt.j2 new file mode 100644 index 0000000..34a3ae5 --- /dev/null +++ b/templates/site/en/list:member:generic:footer.txt.j2 @@ -0,0 +1,4 @@ +-- +$display_name mailing list +$listname +{{ mailman_site_url }}postorius/lists/$list_id/ diff --git a/templates/site/en/list:user:notice:post.txt.j2 b/templates/site/en/list:user:notice:post.txt.j2 new file mode 100644 index 0000000..b4b5b5c --- /dev/null +++ b/templates/site/en/list:user:notice:post.txt.j2 @@ -0,0 +1,9 @@ +Your message entitled + + $subject + +was successfully received by the $display_name mailing list. + +List info page: {{ mailman_site_url }}postorius/lists/$list_id/ +Your preferences: {{ mailman_site_url }}postorius/lists/$list_id/members/options/$user_email + diff --git a/templates/site/en/list:user:notice:probe.txt.j2 b/templates/site/en/list:user:notice:probe.txt.j2 new file mode 100644 index 0000000..34555c4 --- /dev/null +++ b/templates/site/en/list:user:notice:probe.txt.j2 @@ -0,0 +1,20 @@ +This is a probe message. You can ignore this message. + +The $listname mailing list has received a number of bounces from you, +indicating that there may be a problem delivering messages to $address. A +sample is attached below. Please examine this message to make sure there are +no problems with your email address. You may want to check with your mail +administrator for more help. + +You don't need to do anything to remain an enabled member of the mailing list. +You can also visit your membership page at + + {{ mailman_site_url }}postorius/lists/$list_id/members/options/$user_email + +On your membership page, you can change various delivery options such +as your email address and whether you get digests or not. + +If you have any questions or problems, you can contact the mailing list owner +at + + $owner_email diff --git a/templates/site/en/list:user:notice:welcome.txt.j2 b/templates/site/en/list:user:notice:welcome.txt.j2 new file mode 100644 index 0000000..5f1711a --- /dev/null +++ b/templates/site/en/list:user:notice:welcome.txt.j2 @@ -0,0 +1,22 @@ +Welcome to the "$display_name" mailing list! + +To post to this list, send your email to: + + $listname + +General information about the mailing list is at: + + {{ mailman_site_url }}postorius/lists/$list_id/ + +If you ever want to unsubscribe or change your options (eg, switch to or +from digest mode, change your password, etc.), visit your subscription +page at: + + {{ mailman_site_url }}postorius/lists/$list_id/members/options/$user_email + +You can also make such adjustments via email by sending a message to: + + $request_email + +with the word 'help' in the subject or body (don't include the quotes), and +you will get back a message with instructions. diff --git a/templates/site/it/domain:admin:notice:new:list.txt.j2 b/templates/site/it/domain:admin:notice:new:list.txt.j2 new file mode 100644 index 0000000..574d3be --- /dev/null +++ b/templates/site/it/domain:admin:notice:new:list.txt.j2 @@ -0,0 +1,20 @@ +La mailing list '$listname' è stata appena creata per. Quelle che +seguono sono alcune informazioni relative alla gestione della lista. + +È possibile configurare la mailing list a partire dalla pagina web seguente: + + {{ mailman_site_url }}postorius/lists/$list_id/ + +La pagina web con la lista di iscritti alla mailing list è: + + {{ mailman_site_url }}postorius/lists/$list_id/members/member/ + +Esiste anche una interfaccia email-based per gli utenti (non per gli amministratori) +della lista. Per avere informazioni relative sulle modalità di utilizzo è sufficiente +scrivere una email, con la sola parola 'help' nell'oggetto o nel corpo, all'indirizzo: + + $request_email + +Per ulteriori domande, è possibile scrivere a $site_email. + + diff --git a/templates/site/it/list:admin:action:post.txt.j2 b/templates/site/it/list:admin:action:post.txt.j2 new file mode 100644 index 0000000..d40e3ed --- /dev/null +++ b/templates/site/it/list:admin:action:post.txt.j2 @@ -0,0 +1,14 @@ +Come amministratore della lista, è richiesto un suo intervento +per gestire il messaggio seguente: + + List: $listname + From: $sender_email + Subject: $subject + +Che è stato trattenuto a causa di: + +$reasons + +Quando è possibile, dovrebbe visitare + {{ mailman_site_url }}postorius/lists/$list_id/held_messages +per approvare o respingere il messaggio. diff --git a/templates/site/it/list:member:digest:masthead.txt.j2 b/templates/site/it/list:member:digest:masthead.txt.j2 new file mode 100644 index 0000000..c4f1370 --- /dev/null +++ b/templates/site/it/list:member:digest:masthead.txt.j2 @@ -0,0 +1,13 @@ +Send $display_name mailing list submissions to + $listname + +To subscribe or unsubscribe via the World Wide Web, visit + {{ mailman_site_url }}postorius/lists/$list_id/ +or, via email, send a message with subject or body 'help' to + $request_email + +You can reach the person managing the list at + $owner_email + +When replying, please edit your Subject line so it is more specific than +"Re: Contents of $display_name digest..." diff --git a/templates/site/it/list:member:generic:footer.txt.j2 b/templates/site/it/list:member:generic:footer.txt.j2 new file mode 100644 index 0000000..9c5fad5 --- /dev/null +++ b/templates/site/it/list:member:generic:footer.txt.j2 @@ -0,0 +1,5 @@ +-- +$display_name mailing list +$listname +{{ mailman_site_url }}postorius/lists/$list_id/ +Archivio web del messaggio: $hyperkitty_url diff --git a/templates/site/it/list:user:notice:post.txt.j2 b/templates/site/it/list:user:notice:post.txt.j2 new file mode 100644 index 0000000..b52f6c5 --- /dev/null +++ b/templates/site/it/list:user:notice:post.txt.j2 @@ -0,0 +1,8 @@ +Il suo messaggio con oggetto + + $subject + +è stato inviato con successo alla lista $display_name. + +Informazioni sulla lista: {{ mailman_site_url }}postorius/lists/$list_id/ +Preferenze dell'utente: {{ mailman_site_url }}postorius/lists/$list_id/members/options/$user_email diff --git a/templates/site/it/list:user:notice:probe.txt.j2 b/templates/site/it/list:user:notice:probe.txt.j2 new file mode 100644 index 0000000..34555c4 --- /dev/null +++ b/templates/site/it/list:user:notice:probe.txt.j2 @@ -0,0 +1,20 @@ +This is a probe message. You can ignore this message. + +The $listname mailing list has received a number of bounces from you, +indicating that there may be a problem delivering messages to $address. A +sample is attached below. Please examine this message to make sure there are +no problems with your email address. You may want to check with your mail +administrator for more help. + +You don't need to do anything to remain an enabled member of the mailing list. +You can also visit your membership page at + + {{ mailman_site_url }}postorius/lists/$list_id/members/options/$user_email + +On your membership page, you can change various delivery options such +as your email address and whether you get digests or not. + +If you have any questions or problems, you can contact the mailing list owner +at + + $owner_email diff --git a/templates/site/it/list:user:notice:welcome.txt.j2 b/templates/site/it/list:user:notice:welcome.txt.j2 new file mode 100644 index 0000000..20046c4 --- /dev/null +++ b/templates/site/it/list:user:notice:welcome.txt.j2 @@ -0,0 +1,21 @@ +La mailing list "$display_name" le dà il benvenuto! + +Per mandare messaggi alla lista, scrivere a: + + $listname + +Informazioni generali sulla lista sono disponibili alla pagina: + + {{ mailman_site_url }}postorius/lists/$list_id/ + +Per modificare le proprie impostazioni di ricezione dei messaggi dalla lista, +o per cancellare la propria iscrizione, è possibile visitare la pagina: + + {{ mailman_site_url }}postorius/lists/$list_id/members/options/$user_email + +È possibile compiere le stesse operazioni via mail, scrivendo a: + + $request_email + +con la sola parola 'help' nell'oggetto o nel testo del messaggio (senza gli apici). +Verrà spedito un messaggio contenente le istruzioni.