diff options
author | Patrick Wendell <pwendell@gmail.com> | 2013-05-09 11:27:13 -0700 |
---|---|---|
committer | Patrick Wendell <pwendell@gmail.com> | 2013-05-09 11:27:13 -0700 |
commit | 2197b2159a472296af30132a790b74f1442f19c1 (patch) | |
tree | d415b3694c38dd1f736fe33df9b7cd54f810ed10 /ec2 | |
parent | 36c117a1f11252d6892c55f7f012745bf67b74df (diff) | |
download | spark-2197b2159a472296af30132a790b74f1442f19c1.tar.gz spark-2197b2159a472296af30132a790b74f1442f19c1.tar.bz2 spark-2197b2159a472296af30132a790b74f1442f19c1.zip |
Removing unnecessary parsing
Diffstat (limited to 'ec2')
-rwxr-xr-x | ec2/spark_ec2.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/ec2/spark_ec2.py b/ec2/spark_ec2.py index a8b9b07507..b4a5925679 100755 --- a/ec2/spark_ec2.py +++ b/ec2/spark_ec2.py @@ -192,9 +192,7 @@ def get_spark_ami(opts): # TODO(pwendell) Once we have multiple Spark AMI versions, we should let # people give a version flag here in place of just saying 'latest'. version = version[1:] - parts = opts.region.split("-") - region = "-".join([parts[0], parts[1], parts[2][0]]) # strip any avail. zone - ami_path = "%s/%s/%s/%s" % (AMI_PREFIX, version, region, instance_type) + ami_path = "%s/%s/%s/%s" % (AMI_PREFIX, version, opts.region, instance_type) try: ami = urllib2.urlopen(ami_path).read().strip() print "Spark AMI: " + ami |