Skip to content
Snippets Groups Projects
Commit bcb9b7fd authored by Allan Douglas R. de Oliveira's avatar Allan Douglas R. de Oliveira Committed by Patrick Wendell
Browse files

EC2 script should exit with non-zero code on UsageError

This is specially import because some ssh errors are raised as UsageError, preventing an automated usage of the script from detecting the failure.

Author: Allan Douglas R. de Oliveira <allan@chaordicsystems.com>

Closes #638 from douglaz/ec2_exit_code_fix and squashes the following commits:

5915e6d [Allan Douglas R. de Oliveira] EC2 script should exit with non-zero code on UsageError
parent d940e4c1
No related branches found
No related tags found
No related merge requests found
...@@ -814,6 +814,7 @@ def main(): ...@@ -814,6 +814,7 @@ def main():
real_main() real_main()
except UsageError, e: except UsageError, e:
print >> stderr, "\nError:\n", e print >> stderr, "\nError:\n", e
sys.exit(1)
if __name__ == "__main__": if __name__ == "__main__":
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment