Skip to content

Commit 5d6a1c0

Browse files
Jenscarmstrong
authored andcommitted
feat(ec2-provision): add script option to set ELB id when running update-ec2-cluster.sh
1 parent 6bbccb7 commit 5d6a1c0

2 files changed

Lines changed: 14 additions & 3 deletions

File tree

contrib/ec2/update-ec2-cluster.sh

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
#!/usr/bin/env bash
22
#
3-
# Usage: ./provision-ec2-cluster.sh
4-
#
3+
# Usage: ./provision-ec2-cluster.sh [id]
4+
# The [id] defaults to 'deis'
5+
6+
7+
if [ -z "$1" ]
8+
then
9+
ELB_NAME=deis
10+
else
11+
ELB_NAME=$1
12+
fi
513

614
set -e
715

@@ -22,7 +30,7 @@ $CONTRIB_DIR/util/check-user-data.sh
2230
# update the deis EC2 cloudformation
2331
aws cloudformation update-stack \
2432
--template-body "$(./gen-json.py)" \
25-
--stack-name deis \
33+
--stack-name $ELB_NAME \
2634
--parameters "$(<cloudformation.json)"
2735

2836
echo_green "Your Deis cluster CloudFormation has been successfully updated."

docs/installing_deis/aws.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,9 @@ Run the cloudformation provision script to spawn a new CoreOS cluster:
151151

152152
.. code-block:: console
153153
154+
# Usage: ./provision-ec2-cluster.sh [id]
155+
# Where id is internal reference id to the ELB, defaults to 'deis'
156+
154157
$ cd contrib/ec2
155158
$ ./provision-ec2-cluster.sh
156159
{

0 commit comments

Comments
 (0)