Use bash options to have client scripts exit with an error if any
command returns an error (errexit) or if an unset variable is used
(nounset).
Fix those scripts that would otherwise fail due to this change.
Change-Id: I23336bcb5227e884eaf6dd6e9eb5cb0fc24977cc