diff options
Diffstat (limited to 'install')
-rw-r--r-- | install | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/install b/install new file mode 100644 index 000000000000..9e978f3bbcdd --- /dev/null +++ b/install @@ -0,0 +1,31 @@ +post_install() { + getent passwd amavis >/dev/null || useradd -u 333 -d /var/lib/amavis -g amavis -s /bin/false amavis >/dev/null + getent group amavis >/dev/null || groupadd -g 333 amavis >/dev/null + + [ ! -d /var/lib/amavis ] && mkdir /var/lib/amavis + [ ! -d /var/lib/amavis/db ] && mkdir /var/lib/amavis/db + [ ! -d /var/lib/amavis/tmp ] && mkdir /var/lib/amavis/tmp + [ ! -d /var/lib/amavis/var ] && mkdir /var/lib/amavis/var + [ ! -d /var/lib/amavis/virus ] && mkdir /var/lib/amavis/virus + chown -R amavis:amavis /var/lib/amavis + chmod -R 750 /var/lib/amavis +} + +post_upgrade() { + [ "$(vercmp $2 2.6.4-3)" -le 0 ] && cat <<EOF +<<< Attention please! +<<< +<<< The default amavisd-new home directory has been moved to /var/lib/amavis. +<<< +<<< The pid and lock files has been change to /var/run/amavisd. +<<< +<<< The anti-spam and anti-virus features has been disabled by default,you +<<< need to mannully enable them by comment the follow lines in /etc/amavisd.conf +<<< +<<< # @bypass_virus_checks_maps = (1); # controls running of anti-virus code +<<< # @bypass_spam_checks_maps = (1); # controls running of anti-spam code +<<< +<<< Please update you /etc/amavisd/amavisd.conf accordingly. +EOF + post_install +} |