autoupdate.yml aktualisiert
This commit is contained in:
parent
d8dab942a7
commit
31df030286
@ -74,12 +74,13 @@
|
||||
block: |
|
||||
# Server-Config in Git
|
||||
cd /root || exit 0
|
||||
[ -d /root/server-$(hostname -s) ] && rm -r /root/server-$(hostname -s)
|
||||
git clone ssh://git@gitea.ds9.dedyn.io:333/olli/server-$(hostname -s).git >/dev/null 2>&1 || exit 0
|
||||
if [ -e /root/server-$(hostname -s)/$(hostname -s).sh ]
|
||||
then
|
||||
bash -x /root/server-$(hostname -s)/$(hostname -s).sh >/var/log/server-$(hostname -s)-update.log 2>&1
|
||||
g_echo_warn "$(egrep -B1 "^changed" /var/log/server-$(hostname -s)-update.log)"
|
||||
g_echo_error "$(egrep -q -B1 -i '^error|^fatal' /var/log/server-$(hostname -s)-update.log && egrep -B50 '^error|^fatal' /var/log/server-$(hostname -s)-update.log)"
|
||||
g_echo_error "$(egrep -q -B1 -i '^error|^fatal' /var/log/server-$(hostname -s)-update.log && egrep -B50 '^error|^fatal' /var/log/server-$(hostname -s)-update.log)"
|
||||
else
|
||||
g_echo_warn "no server-update-script found /root/server-$(hostname -s)/$(hostname -s).sh"
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user