summaryrefslogtreecommitdiff
path: root/network/mod_evasive/doinst.sh
diff options
context:
space:
mode:
authorMenno E. Duursma <druiloor@zonnet.nl>2010-05-13 00:37:13 +0200
committerErik Hanson <erik@slackbuilds.org>2010-05-13 00:37:13 +0200
commitc34de5f8e296453fae11aac9af5f9c26920ffd6a (patch)
treec1993d0218f625bbbd0850202fb88d6b4c6a4cf0 /network/mod_evasive/doinst.sh
parent6dd98402af4e6d95c8151aebbf92ef9a7a6fd561 (diff)
downloadslackbuilds-c34de5f8e296453fae11aac9af5f9c26920ffd6a.tar.gz
network/mod_evasive: Updated for version 1.10.1
Diffstat (limited to 'network/mod_evasive/doinst.sh')
-rw-r--r--network/mod_evasive/doinst.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/network/mod_evasive/doinst.sh b/network/mod_evasive/doinst.sh
new file mode 100644
index 0000000000..5077bf363e
--- /dev/null
+++ b/network/mod_evasive/doinst.sh
@@ -0,0 +1,15 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+config etc/httpd/mod_evasive.conf.new
+