wok diff postfix/receipt @ rev 18730
Quote root dir in post_install
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sun Dec 20 15:13:45 2015 +0100 (2015-12-20) |
parents | ef162b1d3c0b |
children | c8f848a49bc1 |
line diff
1.1 --- a/postfix/receipt Sat Oct 18 18:59:30 2014 +0200 1.2 +++ b/postfix/receipt Sun Dec 20 15:13:45 2015 +0100 1.3 @@ -84,28 +84,28 @@ 1.4 user=postfix 1.5 group=postdrop 1.6 1.7 - if ! grep -q $user $1/etc/passwd; then 1.8 + if ! grep -q $user "$1/etc/passwd"; then 1.9 echo -n "Adding user/group $user..." 1.10 - chroot $1/ addgroup -S $user 1.11 - chroot $1/ adduser -S -D -H -G $user $user 1.12 - chroot $1/ addgroup -S $group 1.13 + chroot "$1/" addgroup -S $user 1.14 + chroot "$1/" adduser -S -D -H -G $user $user 1.15 + chroot "$1/" addgroup -S $group 1.16 status 1.17 fi 1.18 1.19 # addgroup postdrop if needed 1.20 - if ! grep -q postdrop $1/etc/group; then 1.21 + if ! grep -q postdrop "$1/etc/group"; then 1.22 echo -n "Adding group ${group}..." 1.23 - chroot $1/ addgroup -S $group 1.24 + chroot "$1/" addgroup -S $group 1.25 status 1.26 fi 1.27 1.28 - chroot $1/ chown ${user} /var/spool/postfix/* /var/lib/postfix 1.29 - chroot $1/ chgrp ${group} /var/spool/postfix/maildrop \ 1.30 + chroot "$1/" chown ${user} /var/spool/postfix/* /var/lib/postfix 1.31 + chroot "$1/" chgrp ${group} /var/spool/postfix/maildrop \ 1.32 /var/spool/postfix/public /usr/sbin/postdrop /usr/sbin/postqueue 1.33 - chmod 2755 $1/usr/sbin/postdrop $1/usr/sbin/postqueue 1.34 - chmod 2710 $1/var/spool/postfix/public 1.35 - chmod 1730 $1/var/spool/postfix/maildrop 1.36 - chroot $1/ postalias /etc/postfix/aliases 1.37 + chmod 2755 "$1/usr/sbin/postdrop" "$1/usr/sbin/postqueue" 1.38 + chmod 2710 "$1/var/spool/postfix/public" 1.39 + chmod 1730 "$1/var/spool/postfix/maildrop" 1.40 + chroot "$1/" postalias /etc/postfix/aliases 1.41 cat <<EOF 1.42 1.43 ---- 1.44 @@ -125,7 +125,7 @@ 1.45 # Overlap busybox 1.46 pre_install() 1.47 { 1.48 - rm -f $1/usr/sbin/sendmail 1.49 + rm -f "$1/usr/sbin/sendmail" 1.50 } 1.51 1.52 post_remove()