From e53d651e2f59580fd0c3c658717d8de65ebc3ca9 Mon Sep 17 00:00:00 2001 From: hackbard Date: Sun, 14 Dec 2003 00:02:24 +0000 Subject: [PATCH] added script to update hdw ip in unrealircd --- unreal_update.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 unreal_update.sh diff --git a/unreal_update.sh b/unreal_update.sh new file mode 100755 index 0000000..9b8527a --- /dev/null +++ b/unreal_update.sh @@ -0,0 +1,17 @@ +#!/bin/bash + +# to update ip of hackdaworld.dyndns.org in unrealircd.conf + +CONFIGDIR="/etc/opt/unrealircd" +BINDIR="/opt/unrealircd" +BINARY="ircd" + + +NEWIP="`host hackdaworld.dyndns.org | awk '{ print $4 }'`" + +# HDWTAG dirty ... but easy :) +cat $CONFIGDIR/unrealircd.conf | \ + sed "s/.* HDWTAG .*/hostname $NEWIP \/* HDWTAG *\//" > $CONFDIR/temp +mv $CONFDIR/temp $CONFIGDIR/unrealircd.conf +$BINDIR/$BINARY -rehash + -- 2.20.1