Fix exit code on bootsrap errors in CLI mode (#1489044)