diff options
author | Nicholas Chammas <nicholas.chammas@gmail.com> | 2014-11-03 09:02:35 -0800 |
---|---|---|
committer | Patrick Wendell <pwendell@gmail.com> | 2014-11-05 14:47:29 -0800 |
commit | b27d7dcaaad0bf04d341660ffbeb742cd4eecfd3 (patch) | |
tree | 0c20263f4d5b7cca3be13e3f9a160e2eb8014a63 | |
parent | 68be37b823516dbeda066776bb060bf894db4e95 (diff) | |
download | spark-b27d7dcaaad0bf04d341660ffbeb742cd4eecfd3.tar.gz spark-b27d7dcaaad0bf04d341660ffbeb742cd4eecfd3.tar.bz2 spark-b27d7dcaaad0bf04d341660ffbeb742cd4eecfd3.zip |
[EC2] Factor out Mesos spark-ec2 branch
We reference a specific branch in two places. This patch makes it one place.
Author: Nicholas Chammas <nicholas.chammas@gmail.com>
Closes #3008 from nchammas/mesos-spark-ec2-branch and squashes the following commits:
10a6089 [Nicholas Chammas] factor out mess spark-ec2 branch
-rwxr-xr-x | ec2/spark_ec2.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/ec2/spark_ec2.py b/ec2/spark_ec2.py index 0d6b82b494..50f88f7356 100755 --- a/ec2/spark_ec2.py +++ b/ec2/spark_ec2.py @@ -41,8 +41,9 @@ from boto import ec2 DEFAULT_SPARK_VERSION = "1.1.0" +MESOS_SPARK_EC2_BRANCH = "v4" # A URL prefix from which to fetch AMI information -AMI_PREFIX = "https://raw.github.com/mesos/spark-ec2/v2/ami-list" +AMI_PREFIX = "https://raw.github.com/mesos/spark-ec2/{b}/ami-list".format(b=MESOS_SPARK_EC2_BRANCH) class UsageError(Exception): @@ -583,7 +584,13 @@ def setup_cluster(conn, master_nodes, slave_nodes, opts, deploy_ssh_key): # NOTE: We should clone the repository before running deploy_files to # prevent ec2-variables.sh from being overwritten - ssh(master, opts, "rm -rf spark-ec2 && git clone https://github.com/mesos/spark-ec2.git -b v4") + ssh( + host=master, + opts=opts, + command="rm -rf spark-ec2" + + " && " + + "git clone https://github.com/mesos/spark-ec2.git -b {b}".format(b=MESOS_SPARK_EC2_BRANCH) + ) print "Deploying files to master..." deploy_files(conn, "deploy.generic", opts, master_nodes, slave_nodes, modules) |