summaryrefslogtreecommitdiff
path: root/packages/postfix
diff options
context:
space:
mode:
authorccsmart <ccsmart@smartpal.de>2005-08-06 17:44:20 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2005-08-06 17:44:20 +0000
commit4e11e1c81b2e2f22b6d492af1fbddbc1650b2b76 (patch)
tree752bda92c09f71698da3d2b877bdfb3bf286cd50 /packages/postfix
parent057a7cfc3e2179a9b24d496cd79733824865a693 (diff)
Polishing maildir based install defaults.
Diffstat (limited to 'packages/postfix')
-rw-r--r--packages/postfix/files/main.cf_2.014
-rw-r--r--packages/postfix/postfix_2.0.20.bb12
2 files changed, 21 insertions, 5 deletions
diff --git a/packages/postfix/files/main.cf_2.0 b/packages/postfix/files/main.cf_2.0
index 0bfe4afc1d..1c50b4ae00 100644
--- a/packages/postfix/files/main.cf_2.0
+++ b/packages/postfix/files/main.cf_2.0
@@ -1,11 +1,18 @@
+#!/bin/sh
+cat <<EOF
mydomain=sample.com
virtual_mailbox_domains = sample.com, other.net
-virtual_mailbox_base = /var/spool/vmail
virtual_mailbox_maps = hash:/etc/postfix/virtual
virtual_alias_maps = hash:/etc/postfix/virtual_alias
-virtual_uid_maps = static:vmail
-virtual_gid_maps = static:vmail
+
+# You'll start with the following lines for maildir storage
+virtual_mailbox_base = /var/spool/vmail
+virtual_uid_maps = static:`grep vmail /etc/passwd | cut -d ":" -f 3`
+virtual_gid_maps = static:`grep vmail /etc/passwd | cut -d ":" -f 4`
+
+# You'll start with the following lines for IMAP storage
+
config_directory = /etc/postfix
sample_directory = /etc/postfix
@@ -23,3 +30,4 @@ debug_peer_level = 2
sendmail_path = /usr/sbin/sendmail
newaliases_path = /usr/bin/newaliases
mailq_path = /usr/bin/mailq
+EOF
diff --git a/packages/postfix/postfix_2.0.20.bb b/packages/postfix/postfix_2.0.20.bb
index 3344e05115..f5c22c1139 100644
--- a/packages/postfix/postfix_2.0.20.bb
+++ b/packages/postfix/postfix_2.0.20.bb
@@ -1,7 +1,7 @@
SECTION = "console/network"
DEPENDS = "db3 pcre postfix-native"
LICENSE = "IPL"
-PR = "r1"
+PR = "r2"
SRC_URI = "ftp://ftp.porcupine.org/mirrors/postfix-release/official/postfix-${PV}.tar.gz \
file://${FILESDIR}/makedefs.patch;patch=1 \
@@ -34,7 +34,7 @@ do_install () {
sh ./postfix-install 'install_root=${D}' -non-interactive
rm -rf ${D}/var/spool/postfix
mv ${D}${sysconfdir}/postfix/main.cf ${D}${sysconfdir}/postfix/sample-main.cf
- install -m 644 ${WORKDIR}/main.cf_2.0 ${D}${sysconfdir}/postfix/main.cf
+ install -m 755 ${WORKDIR}/main.cf_2.0 ${D}/var/tmp/main_cf.sh
install -m 644 ${WORKDIR}/volatiles ${D}${sysconfdir}/default/volatiles/01_postfix
install -m 755 ${WORKDIR}/postfix ${D}${sysconfdir}/init.d/postfix
}
@@ -45,6 +45,14 @@ pkg_postinst () {
grep vmail /etc/group || addgroup vmail
grep postfix /etc/passwd || adduser --disabled-password --home=/var/spool/postfix --ingroup postfix postfix
grep vmail /etc/passwd || adduser --disabled-password --home=/var/spool/vmail --ingroup vmail vmail
+ chgrp postdrop /usr/sbin/postqueue
+ chgrp postdrop /usr/sbin/postdrop
+ chmod g+s /usr/sbin/postqueue
+ chmod g+s /usr/sbin/postdrop
+ /var/tmp/main_cf.sh >/etc/postfix/main.cf
+ chmod 644 /etc/postfix/main.cf
/etc/init.d/populate-volatile.sh
+ touch /etc/aliases
+ newaliases
}