Rewrite of boot.sh. Made it more generic to handle
all combinations of login/non-login and interactive/non-interactive.