#
# thomas@linuxmuster.net
# 05.03.2014
# GPL v3
#

echo "### 50_opsi prepatch"

# initial setup
[ "$1" = "--first" -a -n "$opsiip" -a -n "$opsipw" ] && linuxmuster-opsi --setup --password="$opsipw" --first --quiet

# recreate ssh connect
if [ "$1" = "--modify" -a -n "$opsiip" ]; then
 ssh-keygen -f /root/.ssh/known_hosts -R "$opsiip"
 ssh-keygen -f /root/.ssh/known_hosts -R opsi
 test_pwless_opsi
fi
