Mailman Integration Zimbra 7 At ALPHA: Difference between revisions
No edit summary |
No edit summary |
||
| Line 4: | Line 4: | ||
== Update packages: == | == Update packages: == | ||
yum install gcc gcc-c++ python-devel | yum install gcc gcc-c++ python-devel | ||
== Download MailMan Source Code From: == | == Download MailMan Source Code From: == | ||
[http://ftp.gnu.org/gnu/mailman/ http://ftp.gnu.org/gnu/mailman/] | [http://ftp.gnu.org/gnu/mailman/ http://ftp.gnu.org/gnu/mailman/] | ||
http://ftp.gnu.org/gnu/mailman/mailman-2.1.15.tgz | http://ftp.gnu.org/gnu/mailman/mailman-2.1.15.tgz | ||
== Add the group and user:http: == | == Add the group and user:http: == | ||
groupadd mailman | groupadd mailman | ||
useradd -s /sbin/nologin -g mailman mailman | useradd -s /sbin/nologin -g mailman mailman | ||
== Create the installation directory: == | == Create the installation directory: == | ||
As the Environment is on DRBD + Heartbeat , /opt is DRBD mounted partition , which is getting block level replicated to other machine so ensure that mailman is created under /opt | As the Environment is on DRBD + Heartbeat , /opt is DRBD mounted partition , which is getting block level replicated to other machine so ensure that mailman is created under /opt | ||
mkdir -p /opt/mailman | mkdir -p /opt/mailman | ||
ln -s /opt/mailman /usr/local/mailman | ln -s /opt/mailman /usr/local/mailman | ||
== Create the installation directory: == | == Create the installation directory: == | ||
cd /usr/local/ | cd /usr/local/ | ||
chgrp mailman mailman | |||
chgrp mailman mailman | chmod a+rx,g+ws mailman | ||
chmod a+rx,g+ws mailman | |||
== Install Mailman: == | == Install Mailman: == | ||
cd /downloads | cd /downloads | ||
tar xzvf mailman-2.1.15.tgz | |||
tar xzvf mailman-2.1.15.tgz | cd mailman-2.1.15 | ||
./configure --with-username=mailman --with-groupname=mailman --with-mail-gid=mailman --with-cgi-gid=zimbra | |||
cd mailman-2.1.15 | make | ||
make install | |||
./configure --with-username=mailman --with-groupname=mailman --with-mail-gid=mailman --with-cgi-gid=zimbra | |||
make | |||
make install | |||
== Default Installation Path: == | == Default Installation Path: == | ||
Revision as of 13:57, 27 November 2012
Mailman Intregration with Zimbra Server for Nation Today (Alpha)
Update packages:
yum install gcc gcc-c++ python-devel
Download MailMan Source Code From:
http://ftp.gnu.org/gnu/mailman/
http://ftp.gnu.org/gnu/mailman/mailman-2.1.15.tgz
Add the group and user:http:
groupadd mailman
useradd -s /sbin/nologin -g mailman mailman
Create the installation directory:
As the Environment is on DRBD + Heartbeat , /opt is DRBD mounted partition , which is getting block level replicated to other machine so ensure that mailman is created under /opt
mkdir -p /opt/mailman
ln -s /opt/mailman /usr/local/mailman
Create the installation directory:
cd /usr/local/ chgrp mailman mailman chmod a+rx,g+ws mailman
Install Mailman:
cd /downloads tar xzvf mailman-2.1.15.tgz cd mailman-2.1.15 ./configure --with-username=mailman --with-groupname=mailman --with-mail-gid=mailman --with-cgi-gid=zimbra make make install
Default Installation Path:
cd /usr/local/mailman/
bin/check_perms -f
cd archives
chown zimbra private
chmod o-x private
Set up your web server
cd /opt/zimbra/conf/
vim httpd.conf
Write below lines:
ScriptAlias /mailman/ /usr/local/mailman/cgi-bin/
<Directory /usr/local/mailman/cgi-bin/>
AllowOverride None
Options ExecCGI
Order allow,deny
Allow from all
</Directory>
Alias /pipermail/ /usr/local/mailman/archives/public/
<Directory /usr/local/mailman/archives/public>
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
#Uncomment line & Modify
ServerName mail.nationtoday.in:80
save and exit
cd /opt/zimbra/httpd/htdocs
mkdir mmimages
cp /usr/local/mailman/icons/* mmimages/
# Zimbra user
zmapachectl stop
zmapachectl start
Changes postfix configuration
Add/Modify /opt/zimbra/postfix/conf/main.cf so that following varibles are set as shown, as zimbra user
virtual_alias_maps = ldap:/opt/zimbra/conf/ldap vam.cf, hash:/usr/local/mailman/data/ virtual-mailman
alias_maps = hash:/etc/aliases,hash:/usr/local/mailman/data/aliases
save and exit
If It's not changed then u apply below steps:
In /opt/zimbra/conf/zmmta.cf
POSTCONF alias_maps LOCAL postfix_alias_maps
to
POSTCONF alias_maps hash:/usr/local/mailman/data/aliases,hash:/etc/aliases
POSTCONF virtual_alias_maps LOCAL postfix_virtual_alias_maps
to
POSTCONF virtual_alias_maps
hash:/usr/local/mailman/data/virtual-mailman,proxy:ldap:/opt/zimbra/conf/ldap-vam.cf,
and add a line
POSTCONF inet_interfaces all
then su - zimbra
Command:
# zmprov ms node.nationtoday.in zimbraMtaMyDestination '$myhostname,
localhost.$mydomain, localhost'
where node.nationtoday.in is the hostname of the zimbra server
postfix reload
Add following lines at the end of /usr/local/mailman/Mailman/mm_cfg.py file.
DEFAULT_EMAIL_HOST = 'nationtoday.in'
DEFAULT_URL_HOST = 'mail.nationtoday.in'
VIRTUAL_HOSTS.clear()
add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
DEFAULT_URL_PATTERN = 'http://%s:7780/mailman/'
PUBLIC_ARCHIVE_URL = 'http://%(hostname)s/pipermail/%(listname)s'
VIRTUAL_HOST_OVERVIEW = On
MTA = 'Postfix'
POSTFIX_ALIAS_CMD = '/opt/zimbra/postfix/sbin/postalias'
POSTFIX_MAP_CMD = '/opt/zimbra/postfix/sbin/postmap'
IMAGE_LOGOS = '/mmimages/'
POSTFIX_STYLE_VIRTUAL_DOMAINS = [ 'nationtoday.in' ]
save and exit
# Zimbra User
# zmcontrol restart
Add a sitewide list called mailman (Mandatory)
# As root
cd /usr/local/mailman
bin/newlist mailman
bin/config_list -i data/sitelist.cfg mailman
# This is just to make sure that aliases and virtual-mailman files get generated. Until you add a virtual-domain based list, virtual-mailman won't be generated.
# cd /usr/local/mailman
# bin/genaliases
Aliases and virtual-mailman must be owned by mailman.
chown mailman:mailman /usr/local/mailman/data/aliases*
chown mailman:mailman /usr/local/mailman/data/virtual-mailman*
Setup mailman cron
cd /usr/local/mailman/cron
crontab -u mailman crontab.in
Setup daemon
cp /usr/local/mailman/scripts/mailman /etc/init.d
chkconfig --add mailman
Create your first list mailman:
bin/newlist mailman "give the information and password:"
Start the mailman service:
bin/mailmanctl -s start
chown mailman:mailman data/aliases*
chmod g+w data/aliases*
Restart Zimbraserver and Mailman Services
# zmcontrol restart
cd /usr/local/mailman
bin/mailmanctl -s stop
bin/mailmanctl -s start
chkconfig --add mailman
chkconfig mailman on
Set admin password for all list :
bin/mmsitepass