TOOLS-488 Tools exit 1 on error

Closes #890

Signed-off-by: Benety Goh <benety@mongodb.com>