diff options
author | Emmanuel N. Millan <emmanueln __at__ gmail.com> | 2016-10-16 05:10:13 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2016-10-16 05:10:13 +0700 |
commit | 5f8dabb33acac176d9753e276ae72e84b9cdb7d6 (patch) | |
tree | 784299fa2b860f2cd451feb3cabd77c59d8d5b21 /network/ganglia-web/doinst.sh | |
parent | bb8c6397ef078e054720bfb07022cbba47586f52 (diff) |
network/ganglia-web: Added (distributed monitoring web interface).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'network/ganglia-web/doinst.sh')
-rw-r--r-- | network/ganglia-web/doinst.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/network/ganglia-web/doinst.sh b/network/ganglia-web/doinst.sh new file mode 100644 index 0000000000000..63bedaf35de40 --- /dev/null +++ b/network/ganglia-web/doinst.sh @@ -0,0 +1,14 @@ +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/extra/ganglia.conf.new |