summaryrefslogtreecommitdiff
path: root/network/emailrelay/doinst.sh
diff options
context:
space:
mode:
Diffstat (limited to 'network/emailrelay/doinst.sh')
-rw-r--r--network/emailrelay/doinst.sh19
1 files changed, 19 insertions, 0 deletions
diff --git a/network/emailrelay/doinst.sh b/network/emailrelay/doinst.sh
new file mode 100644
index 0000000000..a7d81dcee6
--- /dev/null
+++ b/network/emailrelay/doinst.sh
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+spool="var/spool/emailrelay"
+submit="usr/sbin/emailrelay-submit"
+
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ rm $NEW
+ fi
+}
+
+fix_permissions
+
+config etc/rc.d/rc.emailrelay.new
+config etc/emailrelay.conf.new