Make setup-host.sh more robust