3.11. Configuring GNU Mailman

GNU Mailman is used to help manage the GForge mailing lists. Mailman is frequently installed in /usr/lib64/mailman but sometimes it can be found in /var/mailman. You should change GForge configuration variable $sys_path_to_mailman to that Mailman directory.

Cronjobs for Mailman are located in cronjobs/mail/*. cronjobs/mail/mailing_lists_create.php is used obviously to create new mailing lists.

For all problems with Mailman installation and use, contact the Mailman mailing lists for help.

To install it:

  1. Install a GNU Mailman package or compile it

  2. Don't integrate Mailman with Postfix (or other MTA) by delegating it generation of alias-style file. GForge generates such file. But you'll need to put mail aliases in /etc/aliases for the required standard mailman mailing list. Create it with:

    # /usr/lib64/mailman/bin/newlist mailman
    
  3. Configure mm_cfg.py:

    • DEFAULT_HOST_NAME and DEFAULT_URL should point to lists.gforge.company.com. These variable names may vary depending on Mailman distribution.

    • Strip ugly cgi-bin from URLs in configuration parameters.

  4. su to root and set the Mailman password by using the mmsitepass command

  5. Create directory /var/www/mailman/. It will be document root for lists.gforge.company.com.

  6. In Web server configuraton, create virtual host for Mailman, adjusting ScriptAlias and Alias directives:

    <VirtualHost 1.2.3.4>
      ServerName    lists.gforge.company.com
      ServerAdmin   webmaster@gforge.company.com
    
    # You may want to add these files to logrotate, or just use cronolog as shown below
      CustomLog "/var/log/gforge/lists/access.log" combined
      ErrorLog  "/var/log/gforge/lists/error.log"
    
    #  CustomLog "|/usr/bin/cronolog /var/log/gforge/lists/%Y/%m/%d/access.log" combined
    #  ErrorLog  "|/usr/bin/cronolog /var/log/gforge/lists/%Y/%m/%d/error.log"
    
      DocumentRoot  /var/www/mailman
      DirectoryIndex index.html
      ScriptAlias   /mailman/ /usr/lib/cgi-bin/mailman/
      Alias         /pipermail/ /var/lib/mailman/archives/public/
      Alias         /images/ /usr/share/images/
    </VirtualHost>
    

    Note

    Check that ScriptAlias and Alias directories are correct. The example values are for Debian 3.1 (Sarge).

3.11.1. Mailing list for commits

When repositories are created, mailing list project-commits@lists.gforge.company.com is created too. Note that project administrators should manually set Privacy Options... / Sender filters / accept_these_nonmembers to something like ^.*@servername\.company\.com where servername.company.com is name of the host where Mailman is installed (lists.gforge.company.com).