aboutsummaryrefslogtreecommitdiff
path: root/ec2
diff options
context:
space:
mode:
authorAllan Douglas R. de Oliveira <allan@chaordicsystems.com>2014-05-04 20:36:51 -0700
committerPatrick Wendell <pwendell@gmail.com>2014-05-04 20:36:51 -0700
commitbcb9b7fd4a656f9a6741220a6623441567ded0a4 (patch)
tree05b1b6214fad9747dd950b0411a7ca441935080a /ec2
parentd940e4c16aaa7b60daf1229a99bc4d3455c0240d (diff)
downloadspark-bcb9b7fd4a656f9a6741220a6623441567ded0a4.tar.gz
spark-bcb9b7fd4a656f9a6741220a6623441567ded0a4.tar.bz2
spark-bcb9b7fd4a656f9a6741220a6623441567ded0a4.zip
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
Diffstat (limited to 'ec2')
-rwxr-xr-xec2/spark_ec2.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/ec2/spark_ec2.py b/ec2/spark_ec2.py
index db393748a3..0f6d5a1fa8 100755
--- a/ec2/spark_ec2.py
+++ b/ec2/spark_ec2.py
@@ -814,6 +814,7 @@ def main():
real_main()
except UsageError, e:
print >> stderr, "\nError:\n", e
+ sys.exit(1)
if __name__ == "__main__":