-
Notifications
You must be signed in to change notification settings - Fork 2
/
main.cf
37 lines (33 loc) · 1.28 KB
/
main.cf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
## Based on: http://wiki.alpinelinux.org/wiki/Setting_up_postfix_with_virtual_domains
## These settings differers from the default config ##
#soft_bounce = true # For testing
#myhostname = mail.example.com
#mydomain = example.com
#myorigin = $mydomain
mydestination = localhost, mail.localdomain, localhost.localdomain, localdomain
mynetworks = 192.168.10.0/24, 127.0.0.0/8
relayhost =
in_flow_delay = 1s
home_mailbox = Maildir/
mail_spool_directory = /var/spool/mail
smtpd_banner = $myhostname ESMTP $mail_name ($mail_version)
## The following is added to the config ##
local_transport = virtual
virtual_mailbox_base = /var/spool/mail/vhosts
virtual_mailbox_maps = hash:/etc/postfix/vmailbox
virtual_minimum_uid = 2000
virtual_uid_maps = static:1001
virtual_gid_maps = static:1001
virtual_alias_maps = hash:/etc/postfix/valias
smtpd_helo_required = yes
disable_vrfy_command = yes
smtpd_recipient_restrictions =
reject_unauth_pipelining,
permit_sasl_authenticated,
permit_mynetworks,
reject_invalid_hostname, reject_non_fqdn_hostname,
reject_non_fqdn_sender, reject_non_fqdn_recipient,
reject_unknown_sender_domain, reject_unknown_recipient_domain,
reject_unauth_destination,
permit
smtpd_data_restrictions = reject_unauth_pipelining, permit