- 追加された行はこの色です。
- 削除された行はこの色です。
[[Mailman-2.1.14+j7 install ]]
#author("2023-10-19T05:51:03+09:00","default:kuji","kuji")
CONTENTS
#contents
*Mailman-2.1.14+j7スクラッチインストール [#l5d5ae97]
DLしたMailman-2.1.14+j7.tgz を /usr/local/Mailman-2.1.14+j7.tgz において、解凍すると、/usr/local/mailman-2.1.14+j7 フォルダへ展開される。
cd mailman-2.1.14+j7
----
Lastmodified &lastmod;
----
*/etc/rc.conf [#yf518389]
blackcube# ./configure
checking for --with-python... no
checking for python... /usr/local/bin/python
checking Python interpreter... /usr/local/bin/python
checking Python version... 2.7.2
checking Python's email package... not ok
checking Japanese codecs... ok
checking Korean codecs... ok
checking pykf... not ok
checking that Python has a working distutils... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether make sets $(MAKE)... yes
checking for true... /usr/bin/true
checking for --without-gcc... no
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether #! works in shell scripts... yes
checking for --with-var-prefix... no
checking for --with-permcheck... yes
checking for --with-username... mailman
checking for user name "mailman"... configure: error:
***** No "mailman" user found!
***** Your system must have a "mailman" user defined
***** (usually in your /etc/passwd file). Please see the INSTALL
***** file for details.
といってエラーするので、
portinstall japanese/mailman
した。
mailman_enable="YES"
* portinstall japanese/mailman [#w562ee19]
----------------------------------------------------------------------------
Installing ja-mailman-2.1.14.j7_2,1...
===> Creating groups.
Creating group 'mailman' with gid '91'.
===> Creating users
Creating user 'mailman' with uid '91'.
---> Starting post-install script
---> Running update
Upgrading from version 0x0 to 0x2010ef0
getting rid of old source files
no lists == nothing to do, exiting
---> Checking crontab(5) file for user "mailman"
---> Creating crontab(5) file for user "mailman"
---> Checking (and fixing) file and directory permissions
----------------------------------------------------------------------------
Mailman has been installed, but requires further configuration before use!
Your Postfix hostname is non-default.
You must add "SMTPHOST = blackcube.smb.net" to the bottom of mm_cfg.py.
You will have to configure both your MTA (mail server) and web server to
integrate with Mailman. If the port's documentation has been installed,
extensive post-installation instructions may be found in:
===> Correct pkg-plist sequence to create group(s) and user(s)
===> Registering installation for ja-mailman-2.1.14_5
だそうだ。で、もっぺん、、/usr/local/mailman-2.1.14+j7で、
blackcube# ./configure
checking for --with-python... no
checking for python... /usr/local/bin/python
checking Python interpreter... /usr/local/bin/python
checking Python version... 2.7.2
checking Python's email package... not ok
checking Japanese codecs... ok
checking Korean codecs... ok
checking pykf... not ok
略
config.status: creating build/cron/nightly_gzip
config.status: creating build/cron/senddigests
config.status: executing default commands
configuration completed at Tue Dec 13 13:02:14 JST 2011
blackcube#
でおk。で、portinstall した mailman を mailman_portinstalled へmv
drwxr-xr-x 14 root wheel 1024 Dec 13 13:02 mailman-2.1.14+j7
-rw-r--r-- 1 root wheel 8679318 Dec 13 12:25 mailman-2.1.14+j7.gz
drwxrwsr-x 20 mailman mailman 512 Dec 13 12:59 mailman_portinstalled
で,
make install
/usr/local/share/doc/mailman/FreeBSD-post-install-notes
Note (1): If you use an alternate MTA (meaning "not Sendmail"), you MUST
be sure that the correct value of MAIL_GID was used when this port or
package was built. You can choose your MTA with the correct MAIL_GID by
running "make config" in the Mailman port directory.
Note (2): The entire Mailman installation resides under /usr/local/mailman.
The command-line scripts necessary to administer Mailman have been
installed in /usr/local/mailman/bin.
Note (3): As of version 2.1, Mailman's queue runner runs as a daemon and
is started by a script in /usr/local/etc/rc.d
In order to make private archives searchable with namazu2, you need copy
or link /usr/local/libexec/namazu.cgi to
/usr/local/mailman/archives/private/<ML_name>/ and configure .namazurc
to refer to /usr/local/etc/namazu/namazu-sample.
You can also see the Japanese document in
<http://www.python.jp/pipermail/mailman-users-jp/2004-August/001008.html>
----------------------------------------------------------------------------
===> SECURITY REPORT:
This port has installed the following binaries which execute with
increased privileges.
/usr/local/mailman/cgi-bin/create
/usr/local/mailman/cgi-bin/subscribe
/usr/local/mailman/mail/mailman
/usr/local/mailman/cgi-bin/listinfo
/usr/local/mailman/cgi-bin/rmlist
/usr/local/mailman/cgi-bin/options
/usr/local/mailman/cgi-bin/private
/usr/local/mailman/cgi-bin/admindb
/usr/local/mailman/cgi-bin/edithtml
/usr/local/mailman/cgi-bin/roster
/usr/local/mailman/cgi-bin/admin
/usr/local/mailman/cgi-bin/confirm
If there are vulnerabilities in these programs there may be a security
risk to the system. FreeBSD makes no guarantee about the security of
ports included in the Ports Collection. Please type 'make deinstall'
to deinstall the port if this is a concern.
For more information, and contact details about the security
status of this software, see the following webpage:
http://www.python.jp/doc/contrib/mailman/releases.html
===> Cleaning for ja-mailman-2.1.14.j7_2,1
drwxr-xr-x 20 root wheel 512 Dec 13 13:08 mailman
drwxr-xr-x 14 root wheel 1024 Dec 13 13:02 mailman-2.1.14+j7
-rw-r--r-- 1 root wheel 8679318 Dec 13 12:25 mailman-2.1.14+j7.gz
drwxrwsr-x 20 mailman mailman 512 Dec 13 12:59 mailman_portinstalled
となりまつ。
blackcube# chown -R mailman:mailman mailman
blackcube# cd mailman
blackcube# ll
blackcube# bin/check_perms -f
blackcube# chown www /usr/local/mailman/archives/private
blackcube# chmod o-x /usr/local/mailman/archives/private
blackcube# bin/check_perms -f
No problems found
*Apacheとの接続 [#l83d1d25]
/usr/local/etc/apache22/Includes/mailman.conf
/usr/local/etc/apache24/Includes/mailman.conf
<IfModule alias_module>
ScriptAlias /mailman/ "/usr/local/mailman/cgi-bin/"
Alias /pipermail/ "/usr/local/mailman/archives/public/"
ScriptAlias /mailman/ "/usr/local/mailman/cgi-bin/"
Alias /pipermail/ "/usr/local/mailman/archives/public/"
Alias /icons/ "/usr/local/www/icons/"
</IfModule>
<Directory "/usr/local/mailman">
<Directory "/usr/local/mailman/">
Options FollowSymLinks ExecCGI
AllowOverride None
Order allow,deny
Allow from all
Require all granted
</Directory>
<Directory "/usr/local/www/icons/">
Require all granted
</Directory>
blackcube# apachectl configtest
Syntax OK
blackcube# apachectl restart
blackcube#
*Postfixとの接続 [#vadc2d31]
# vi /usr/local/etc/postfix/main.cf
alias_maps = hash:/etc/mail/aliases
alias_database = hash:/etc/mail/aliases
↓(変更する)↓
alias_maps = hash:/etc/mail/aliases,
hash:/usr/local/mailman/data/aliases <--行頭にTABをいれる
alias_database = hash:/etc/mail/aliases, hash:/usr/local/mailman/data/aliases
owner_request_special = no
recipient_delimiter = +
unknown_local_recipient_reject_code = 550
postfix reload
*mailmanの設定 [#o4800a67]
# Put YOUR site-specific settings below this line.
DEFAULT_SERVER_LANGUAGE = 'ja'
DEFAULT_EMAIL_HOST = 'mail.smb.net'
DEFAULT_URL_HOST = 'www.smb.net'
MTA = 'Postfix'
USE_MAILMAN_MESSAGE_ID = Yes
"SMTPHOST = blackcube.smb.net"
設定のデフォルト値 [[Defaults.py.2_1_39.utf-8.txt:https://mm.poem.co.jp/mailman-jp/ja_translations/Defaults.py.2_1_39.utf-8.txt]]
*mailmanで新しいリストを作る [#ifcc7049]
bin/genaliases スクリプトを実行して aliases ファイルを初期化しようとすると
blackcube# bin/genaliases
/usr/sbin/postalias: not found
Traceback (most recent call last):
File "bin/genaliases", line 124, in <module>
main()
File "bin/genaliases", line 118, in main
MTA.create(None, quiet=True)
File "/usr/local/mailman/Mailman/MTA/Postfix.py", line 241, in create
_update_maps()
File "/usr/local/mailman/Mailman/MTA/Postfix.py", line 53, in _update_maps
raise RuntimeError, msg % (acmd, status, errstr)
RuntimeError: command failed: /usr/sbin/postalias /usr/local/mailman/data/aliases (status: 127, Unknown error: 127)
また、新しいリストを作ろうとして、
bin/genaliases スクリプトを実行して aliases ファイルを初期化
また、新しいリストを作っておかないと、mailman の qランナー が起動しない
blackcube# bin/newlist mailman
Enter the email of the person running the list: kuji@smb.net
Initial mailman password:
/usr/sbin/postalias: not found
Traceback (most recent call last):
File "bin/newlist", line 259, in <module>
main()
File "bin/newlist", line 226, in main
sys.modules[modname].create(mlist)
File "/usr/local/mailman/Mailman/MTA/Postfix.py", line 241, in create
_update_maps()
File "/usr/local/mailman/Mailman/MTA/Postfix.py", line 53, in _update_maps
raise RuntimeError, msg % (acmd, status, errstr)
RuntimeError: command failed: /usr/sbin/postalias /usr/local/mailman/data/aliases (status: 127, Unknown error: 127)
blackcube#
Enter the email of the person running the list: kuji@my.domain
Initial mailman password: hogehoge
すると kuji@my.domain へ、新規リスト作成報告メールが届く。
/usr/sbin/postalias が無い!といって止まる。確かに/usr/sbin/postalias はなくて、/usr/local/sbin/postalias はある。ので、
blackcube# ln -s /usr/local/sbin/postalias postalias
する。
http://maniawanele.blog64.fc2.com/blog-entry-24.html
* リスト削除 [#o36daebd]
/usr/local/mailman/Mailman/mm_cfg.py
OWNERS_CAN_DELETE_THEIR_OWN_LISTS = yes
とすると、管理画面から削除できる。アーカイブは残る。
*icon favicon を表示 [#g299a00f]
/usr/local/mailman/icons を /usr/local/www/apache24/data/icons へコピーする
cp -rpv /usr/local/mailman/icons /usr/local/www/apache24/data/
----
Total access &counter(total);:本日 &counter(today);:昨日 &counter(yesterday);
#counter([total|today|yesterday]);