- user : root
- host : grodoudou.seizam.com
- date : 14/06/12 16:56
- curpath : /root
[email protected]# apt-get update
[email protected]# apt-get install exim4
[email protected]# dpkg-reconfigure exim4-config
Please select the mail server configuration type that best meets your needs.
mail sent by smarthost; no local mail
System mail name:
grodoudou.seizam.com
IP-addresses to listen on for incoming SMTP connections:
127.0.0.1 ; ::1
Other destinations for which mail is accepted:
<blank>
Visible domain name for local users:
grodoudou.seizam.com
IP address or host name of the outgoing smarthost:
smtp.gmail.com::587
Keep number of DNS-queries minimal (Dial-on-Demand)?
No
Split configuration into small files?
No
- Default "routes" need to be changed, see next command output
[email protected]# exim4 -brw root
sender: [email protected]
from: [email protected]
to: [email protected]
cc: [email protected]
bcc: [email protected]
reply-to: [email protected]
env-from: [email protected]
env-to: [email protected]
- Edit /etc/email-addresses, see [1]
- Edit /etc/exim4/exim4.conf.template, see [2]
- Edit /etc/exim4/passwd.client, see [3] set Gmail account password
[email protected]# update-exim4.conf
[email protected]# /etc/init.d/exim4 restart
[email protected]# exim4 -qff
[email protected]# exim4 -brw root
sender: [email protected]
from: [email protected]
to: [email protected]
cc: [email protected]
bcc: [email protected]
reply-to: [email protected]
env-from: [email protected]
env-to: [email protected]
[email protected]# exim4 -brw www-data
sender: [email protected]
from: [email protected]
to: [email protected]
cc: [email protected]
bcc: [email protected]
reply-to: [email protected]
env-from: [email protected]
env-to: [email protected]
[email protected]# exim4 -brw [email protected]
sender: [email protected]
from: [email protected]
to: [email protected]
cc: [email protected]
bcc: [email protected]
reply-to: [email protected]
env-from: [email protected]
env-to: [email protected]
[email protected]# echo "This is the body of an email sent from root@grodoudou ." | mail -s "Grodoudou Exim4 test" root
[email protected]# tail /var/log/exim4/mainlog
2012-06-14 17:07:31 1SfBdz-0006E2-Ng <= [email protected] U=root P=local S=571
2012-06-14 17:07:32 1SfBdz-0006E2-Ng => [email protected] R=smarthost T=remote_smtp_smarthost H=gmail-smtp-msa.l.google.com [173.194.67.109] X=TLS1.0:RSA_ARCFOUR_SHA1:16 DN="C=US,ST=California,L=Mountain View,O=Google Inc,CN=smtp.gmail.com"
2012-06-14 17:07:32 1SfBdz-0006E2-Ng Completed
- Now update Wikizam config
- Edit /var/wikizam/_ServerSettings.php, see [4]
[email protected]# ./update-and-deploy-wikizam-trunk.sh
- Now, this is the header in mail sent by Wikizam
Received: from www-data by grodoudou.seizam.com with local (Exim 4.72)
(envelope-from <[email protected]>)
id 1SfCDF-0006o4-HT
for [email protected]; Thu, 14 Jun 2012 17:43:57 +0200
Date: Thu, 14 Jun 2012 17:43:57 +0200
Message-Id: <[email protected]>
To: Yannouk <[email protected]>
Subject: =?UTF-8?Q?Confirmation=20d=E2=80=99adresse=20de=20courriel=20pour=20Seizam?=
X-PHP-Originating-Script: 0:UserMailer.php
MIME-Version: 1.0
Content-type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Mailer: MediaWiki mailer
From: Seizam Mail <[email protected]>
- [1] Edit /etc/email-addresses
--- old 2012-06-14 16:59:02.000000000 +0200
+++ new 2012-06-14 16:59:53.000000000 +0200
@@ -9 +9,11 @@
#otheruser: [email protected]
+root: [email protected]
+root@localhost: [email protected]
+root@grodoudou: [email protected]
[email protected]: [email protected]
[email protected]: [email protected]
+www-data: [email protected]
+www-data@localhost: [email protected]
+www-data@grodoudou: [email protected]
[email protected]: [email protected]
[email protected]: [email protected]
- [2] Edit /etc/exim4/exim4.conf.template
--- old 2012-06-14 17:00:07.000000000 +0200
+++ new 2012-06-14 17:01:17.000000000 +0200
@@ -1747,2 +1747,3 @@
+*@grodoudou.seizam.com [email protected] tcbT
- [3] Edit /etc/exim4/passwd.client
--- old 2012-06-14 17:01:37.000000000 +0200
+++ new 2012-06-14 17:03:11.000000000 +0200
@@ -7 +7,2 @@
### target.mail.server.example:login:password
+*.google.com:[email protected]:THE_PASSWORD
- [4] Edit /var/wikizam/_ServerSettings.php
--- old 2012-06-14 17:41:43.000000000 +0200
+++ new 2012-06-14 17:42:46.000000000 +0200
@@ -61,2 +61,3 @@
# Mail sending
+/*
$wgSMTP = array(
@@ -66,5 +67,6 @@
'username' => '[email protected]',
- 'password' => 'old_password',
+ 'password' => 'THE_PASSWORD',
'auth' => true
);
+*/