Use mailman to set up mailing lists

Source: Internet
Author: User
Tags add mail modify access

1 Installing the Mailing list program

Apt-get Install Mailman

2 Modify configuration/etc/mailman/mm_cfg.py This server uses exim4 as mail Service

Default_email_host = ' lists.mydomain.com '

Default_url_host = ' www.mydomain.com '

MTA = None

3 Add a default mailing list

NewList Mailman

4 Set up mailing list Administrator account

Mmsitepass

5 Setting up Web Access increases in the Apache configuration file:

代码:
ScriptAlias /mailman/ /usr/lib/cgi-bin/mailman/
    Alias /pipermail/ /var/lib/mailman/archives/public/
    RedirectMatch ^/*$ http://www.mydomain.com/mailman/listinfo
    <Directory "/var/lib/mailman/archives/public/">
      AddDefaultCharset Off
    </Directory>
    <Directory "/usr/lib/cgi-bin/mailman/">
       AllowOverride None
       Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
       Order allow,deny
       Allow from all
    </Directory>

Using http://www.mydomain.com/to access

6 Modifying EXIM4 configuration

Increase:

Mm_home=/var/lib/mailman

Mm_uid=list

Mm_gid=list

DomainList mm_domains=lists.mydomain.com

Mm_wrap=mm_home/mail/mailman

MM_LISTCHK=MM_HOME/LISTS/${LC:: $local _PART}/CONFIG.PCK

Increase Router:

代码:
mailman_router:
  driver = accept
  domains = +mm_domains
  require_files = MM_LISTCHK
  local_part_suffix_optional
  local_part_suffix = -admin  :
-bounces : -bounces+* :
            -confirm : -confirm+* :
-join   : -leave  :
-owner  : -request :
-subscribe : -unsubscribe
  transport = mailman_transport

Increase Transport:

代码:
mailman_transport:
  driver = pipe
  command = MM_WRAP
       '${if def:local_part_suffix
          {${sg{$local_part_suffix}{-(\w+)(\+.*)?}{$1}}}
          {post}}'
       $local_part
  current_directory = MM_HOME
  home_directory = MM_HOME
  user = MM_UID
  group = MM_GID

Perform/etc/init.d/exim4 reload

Check:

代码:
# exim4 -bt test@lists.mydomain.com
 test@lists.mydomain.com
  router = mailman_router, transport = mailman_transport

7 Modify Admin Forwarding account number

Modify/etc/aliases Add:

Mailman:root

Mailman-owner:mailman

The execution newaliases has been added to completion.

8 Start Mailman

/etc/init.d/mailman start

9 Start a scheduled task

Cd/usr/lib/mailman/cron

Crontab crontab.in

All right, finish it!



Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.