~xav0989/ubuntu/vivid/mailman/ubuntu-logo

« back to all changes in this revision

Viewing changes to admin/www/mailman-install/node13.html

  • Committer: Bazaar Package Importer
  • Author(s): Thijs Kinkhorst
  • Date: 2008-04-24 19:30:49 UTC
  • mfrom: (1.1.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20080424193049-jy5fa9tus40tjbmn
Tags: 1:2.1.10-2
Apply upstream patch to fix regression in cmd_subscribe
so that email subscribe to the -subscribe or -join address or the
-request address with a bare 'subscribe' command results in the message
being shunted.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2
 
<html>
3
 
<head>
4
 
<link rel="STYLESHEET" href="mailman-install.css" type='text/css' />
5
 
<link rel="first" href="mailman-install.html" title='GNU Mailman - Installation Manual' />
6
 
<link rel='last' href='about.html' title='About this document...' />
7
 
<link rel='help' href='about.html' title='About this document...' />
8
 
<link rel="next" href="postfix-virtual.html" />
9
 
<link rel="prev" href="node12.html" />
10
 
<link rel="parent" href="node12.html" />
11
 
<link rel="next" href="postfix-virtual.html" />
12
 
<meta name='aesop' content='information' />
13
 
<title>6.1.1 Integrating Postfix and Mailman</title>
14
 
</head>
15
 
<body>
16
 
<DIV CLASS="navigation">
17
 
<div id='top-navigation-panel' xml:id='top-navigation-panel'>
18
 
<table align="center" width="100%" cellpadding="0" cellspacing="2">
19
 
<tr>
20
 
<td class='online-navigation'><a rel="prev" title="6.1 Using the Postfix"
21
 
  href="node12.html"><img src='previous.png'
22
 
  border='0' height='32'  alt='Previous Page' width='32' /></A></td>
23
 
<td class='online-navigation'><a rel="parent" title="6.1 Using the Postfix"
24
 
  href="node12.html"><img src='up.png'
25
 
  border='0' height='32'  alt='Up One Level' width='32' /></A></td>
26
 
<td class='online-navigation'><a rel="next" title="6.1.2 Virtual domains"
27
 
  href="postfix-virtual.html"><img src='next.png'
28
 
  border='0' height='32'  alt='Next Page' width='32' /></A></td>
29
 
<td align="center" width="100%">GNU Mailman - Installation Manual</td>
30
 
<td class='online-navigation'><img src='blank.png'
31
 
  border='0' height='32'  alt='' width='32' /></td>
32
 
<td class='online-navigation'><img src='blank.png'
33
 
  border='0' height='32'  alt='' width='32' /></td>
34
 
<td class='online-navigation'><img src='blank.png'
35
 
  border='0' height='32'  alt='' width='32' /></td>
36
 
</tr></table>
37
 
<div class='online-navigation'>
38
 
<b class="navlabel">Previous:</b>
39
 
<a class="sectref" rel="prev" href="node12.html">6.1 Using the Postfix</A>
40
 
<b class="navlabel">Up:</b>
41
 
<a class="sectref" rel="parent" href="node12.html">6.1 Using the Postfix</A>
42
 
<b class="navlabel">Next:</b>
43
 
<a class="sectref" rel="next" href="postfix-virtual.html">6.1.2 Virtual domains</A>
44
 
</div>
45
 
<hr /></div>
46
 
</DIV>
47
 
<!--End of Navigation Panel-->
48
 
 
49
 
<H3><A NAME="SECTION001611000000000000000">
50
 
6.1.1 Integrating Postfix and Mailman</A>
51
 
</H3>
52
 
 
53
 
<P>
54
 
You can integrate Postfix and Mailman such that when new lists are created, or
55
 
lists are removed, Postfix's alias database will be automatically updated.
56
 
The following are the steps you need to take to make this work.
57
 
 
58
 
<P>
59
 
In the description below, we assume that you've installed Mailman in the
60
 
default location, i.e. <span class="file">/usr/local/mailman</span>.  If that's not the case,
61
 
adjust the instructions according to your use of <b class="program">configure</b>'s
62
 
<b class="programopt">--prefix</b> and <b class="programopt">--with-var-prefix</b> options.
63
 
 
64
 
<P>
65
 
<div class="note"><b class="label">Note:</b>
66
 
 
67
 
If you are using virtual domains and you want Mailman to honor your virtual
68
 
domains, read the <A href="postfix-virtual.html#postfix-virtual">6.1</A> section below first!
69
 
</div>
70
 
 
71
 
<P>
72
 
 
73
 
<UL>
74
 
<LI>Add this to the bottom of the <span class="file"><var>$prefix</var>/Mailman/mm_cfg.py</span>
75
 
      file:
76
 
 
77
 
<P>
78
 
<div class="verbatim"><pre>
79
 
        MTA = 'Postfix'
80
 
</pre></div>
81
 
 
82
 
<P>
83
 
The MTA variable names a module in the <span class="file">Mailman/MTA</span> directory
84
 
      which contains the mail server-specific functions to be executed when a
85
 
      list is created or removed.
86
 
 
87
 
<P>
88
 
</LI>
89
 
<LI>Look at the <span class="file">Defaults.py</span> file for the variables
90
 
      <var>POSTFIX_ALIAS_CMD</var> and <var>POSTFIX_MAP_CMD</var> command.  Make sure
91
 
      these point to your <b class="program">postalias</b> and <b class="program">postmap</b> programs
92
 
      respectively.  Remember that if you need to make changes, do it in
93
 
      <span class="file">mm_cfg.py</span>.
94
 
 
95
 
<P>
96
 
</LI>
97
 
<LI>Run the <b class="program">bin/genaliases</b> script to initialize your
98
 
      <span class="file">aliases</span> file.
99
 
 
100
 
<P>
101
 
<div class="verbatim"><pre>
102
 
        % cd /usr/local/mailman
103
 
        % bin/genaliases
104
 
      </pre></div>
105
 
 
106
 
<P>
107
 
Make sure that the owner of the <span class="file">data/aliases</span> and
108
 
      <span class="file">data/aliases.db</span> file is <code>mailman</code>, that the group owner
109
 
      for those files is <code>mailman</code>, or whatever user and group you used
110
 
      in the configure command, and that both files are group writable:
111
 
 
112
 
<P>
113
 
<div class="verbatim"><pre>
114
 
        % su
115
 
        % chown mailman:mailman data/aliases*
116
 
        % chmod g+w data/aliases*
117
 
      </pre></div>
118
 
 
119
 
<P>
120
 
</LI>
121
 
<LI>Hack your Postfix's <span class="file">main.cf</span> file to include the following path in
122
 
      your <var>alias_maps</var> variable:
123
 
 
124
 
<P>
125
 
<div class="verbatim"><pre>
126
 
          /usr/local/mailman/data/aliases
127
 
</pre></div>
128
 
 
129
 
<P>
130
 
Note that there should be no trailing <code>.db</code>.  Do not include this
131
 
      in your <var>alias_database</var> variable.  This is because you do not want
132
 
      Postfix's <b class="program">newaliases</b> command to modify Mailman's
133
 
      <span class="file">aliases.db</span> file, but you do want Postfix to consult
134
 
      <span class="file">aliases.db</span> when looking for local addresses.
135
 
 
136
 
<P>
137
 
You probably want to use a <code>hash:</code> style database for this entry.
138
 
      Here's an example:
139
 
 
140
 
<P>
141
 
<div class="verbatim"><pre>
142
 
        alias_maps = hash:/etc/postfix/aliases,
143
 
            hash:/usr/local/mailman/data/aliases
144
 
</pre></div>
145
 
 
146
 
<P>
147
 
</LI>
148
 
<LI>When you configure Mailman, use the
149
 
      <b class="programopt">--with-mail-gid=mailman</b> switch; this will be the default
150
 
      if you configured Mailman after adding the <code>mailman</code> owner.
151
 
      Because the owner of the <span class="file">aliases.db</span> file is <code>mailman</code>,
152
 
      Postfix will execute Mailman's wrapper program as uid and gid
153
 
      <code>mailman</code>.
154
 
 
155
 
<P>
156
 
</LI>
157
 
</UL>
158
 
 
159
 
<P>
160
 
That's it!  One caveat: when you add or remove a list, the <span class="file">aliases.db</span>
161
 
file will updated, but it will not automatically run <b class="program">postfix reload</b>.
162
 
This is because you need to be root to run this and suid-root scripts are not
163
 
secure.  The only effect of this is that it will take about a minute for
164
 
Postfix to notice the change to the <span class="file">aliases.db</span> file and update its
165
 
tables.
166
 
 
167
 
<P>
168
 
 
169
 
<DIV CLASS="navigation">
170
 
<div class='online-navigation'>
171
 
<p></p><hr />
172
 
<table align="center" width="100%" cellpadding="0" cellspacing="2">
173
 
<tr>
174
 
<td class='online-navigation'><a rel="prev" title="6.1 Using the Postfix"
175
 
  href="node12.html"><img src='previous.png'
176
 
  border='0' height='32'  alt='Previous Page' width='32' /></A></td>
177
 
<td class='online-navigation'><a rel="parent" title="6.1 Using the Postfix"
178
 
  href="node12.html"><img src='up.png'
179
 
  border='0' height='32'  alt='Up One Level' width='32' /></A></td>
180
 
<td class='online-navigation'><a rel="next" title="6.1.2 Virtual domains"
181
 
  href="postfix-virtual.html"><img src='next.png'
182
 
  border='0' height='32'  alt='Next Page' width='32' /></A></td>
183
 
<td align="center" width="100%">GNU Mailman - Installation Manual</td>
184
 
<td class='online-navigation'><img src='blank.png'
185
 
  border='0' height='32'  alt='' width='32' /></td>
186
 
<td class='online-navigation'><img src='blank.png'
187
 
  border='0' height='32'  alt='' width='32' /></td>
188
 
<td class='online-navigation'><img src='blank.png'
189
 
  border='0' height='32'  alt='' width='32' /></td>
190
 
</tr></table>
191
 
<div class='online-navigation'>
192
 
<b class="navlabel">Previous:</b>
193
 
<a class="sectref" rel="prev" href="node12.html">6.1 Using the Postfix</A>
194
 
<b class="navlabel">Up:</b>
195
 
<a class="sectref" rel="parent" href="node12.html">6.1 Using the Postfix</A>
196
 
<b class="navlabel">Next:</b>
197
 
<a class="sectref" rel="next" href="postfix-virtual.html">6.1.2 Virtual domains</A>
198
 
</div>
199
 
</div>
200
 
<hr />
201
 
<span class="release-info">Release 2.1, documentation updated on December 13, 2005.</span>
202
 
</DIV>
203
 
<!--End of Navigation Panel-->
204
 
 
205
 
</BODY>
206
 
</HTML>