Fix the auth ACL for hyperkitty.

This commit is contained in:
Andrea Dell'Amico 2020-02-14 19:51:07 +01:00
parent 6413bd8d1b
commit c8ae475df9
3 changed files with 15 additions and 7 deletions

View File

@ -99,6 +99,7 @@ mailman_postorious_site_id: 2
mailman_postorious_allowed_hosts:
- 'localhost'
- '{{ ansible_fqdn }}'
mailman_postorious_hyperkitty_acl: "'127.0.0.1', '::1', '{{ ansible_default_ipv4.address }}'"
mailman_postorious_settings_files:
- { name: 'manage.py', perms: '0750' }
@ -113,3 +114,4 @@ mailman_postorious_db_host: 'localhost'
mailman_postorious_db_port: ''
mailman_use_hyperkitty_archiver: True

View File

@ -144,6 +144,8 @@
when: mailman_use_hyperkitty_archiver | bool
register: mailman_hyperkitty_install
tags: [ 'mailman', 'postorious', 'hyperkitty', 'mailman_conf' ]
- name: Manage the mailman service
block:
- name: Ensure that the mailman service is started and enabled

View File

@ -57,7 +57,7 @@ MAILMAN_REST_API_URL = 'http://localhost:8001'
MAILMAN_REST_API_USER = '{{ mailman_api_user }}'
MAILMAN_REST_API_PASS = '{{ mailman_vault_rest_api_pwd }}'
MAILMAN_ARCHIVER_KEY = '{{ mailman_archiver_crypt_key }}'
MAILMAN_ARCHIVER_FROM = ('127.0.0.1', '::1')
MAILMAN_ARCHIVER_FROM = ({{ mailman_postorious_hyperkitty_acl }})
# Application definition
@ -287,11 +287,6 @@ MESSAGE_TAGS = {
#
# Social auth
#
AUTHENTICATION_BACKENDS = (
'django.contrib.auth.backends.ModelBackend',
'allauth.account.auth_backends.AuthenticationBackend',
)
# Django Allauth
ACCOUNT_AUTHENTICATION_METHOD = "username_email"
ACCOUNT_EMAIL_REQUIRED = True
@ -301,6 +296,11 @@ ACCOUNT_DEFAULT_HTTP_PROTOCOL = "https"
ACCOUNT_UNIQUE_EMAIL = True
{% if mailman_use_social_account_providers %}
AUTHENTICATION_BACKENDS = (
'django.contrib.auth.backends.ModelBackend',
'allauth.account.auth_backends.AuthenticationBackend',
)
SOCIALACCOUNT_PROVIDERS = {
'openid': {
'SERVERS': [
@ -328,7 +328,11 @@ SOCIALACCOUNT_PROVIDERS = {
},
}
{% else %}
SOCIALACCOUNT_PROVIDERS = { '' }
AUTHENTICATION_BACKENDS = (
'django.contrib.auth.backends.ModelBackend',
)
SOCIALACCOUNT_PROVIDERS = { }
{% endif %}
#