diff options
author | Marco Bonetti <sid77@slackware.it> | 2010-04-12 19:35:52 -0400 |
---|---|---|
committer | David Somero <xgizzmo@slackbuilds.org> | 2010-05-15 10:37:53 +0200 |
commit | 5ecb604087273dc1238572705d7995cd2c1b48dd (patch) | |
tree | ca4407aad1385a52b93cbf66a17f38de2c2f657f /network/greenbone-security-assistant/doinst.sh | |
parent | a7c3b4f62b40315e6eca57e772f21181d956285f (diff) | |
download | slackbuilds-5ecb604087273dc1238572705d7995cd2c1b48dd.tar.gz |
network/greenbone-security-assistant: Added (OpenVAS web interface)
Diffstat (limited to 'network/greenbone-security-assistant/doinst.sh')
-rw-r--r-- | network/greenbone-security-assistant/doinst.sh | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/network/greenbone-security-assistant/doinst.sh b/network/greenbone-security-assistant/doinst.sh new file mode 100644 index 0000000000..42955bb4c9 --- /dev/null +++ b/network/greenbone-security-assistant/doinst.sh @@ -0,0 +1,22 @@ +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... +} + +# Keep same perms on rc.gsad.new: +if [ -e etc/rc.d/rc.gsad ]; then + cp -a etc/rc.d/rc.gsad etc/rc.d/rc.gsad.new.incoming + cat etc/rc.d/rc.gsad.new > etc/rc.d/rc.gsad.new.incoming + mv etc/rc.d/rc.gsad.new.incoming etc/rc.d/rc.gsad.new +fi + +config etc/rc.d/rc.gsad.new +config etc/openvas/gsad_log.conf.new + |