Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
configuration
Commits
2bc8c027
Commit
2bc8c027
authored
May 02, 2013
by
John Jarvis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
updating the rolling upgrade example to use the new module
parent
e4146b31
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
13 deletions
+12
-13
playbooks/edxapp_rolling_example.yml
+12
-13
No files found.
playbooks/edxapp_rolling_example.yml
View file @
2bc8c027
...
@@ -8,21 +8,20 @@
...
@@ -8,21 +8,20 @@
pre_tasks
:
pre_tasks
:
-
name
:
Gathering ec2 facts
-
name
:
Gathering ec2 facts
ec2_facts
:
ec2_facts
:
-
name
:
Gathering ELB facts
-
name
:
Removing instance from the ELB
local_action
:
ec2_elb_facts
local_action
:
ec2_elb
# These two modules "ec2_facts" and "ec2_elb_facts" are invoked in the
args
:
# pre_tasks and give us the $elbs and $ansible_ec2_isntance_id facts
instance_id
:
"
{{
ansible_ec2_instance_id
}}"
# which are variables that can be used in the playbook
state
:
'
absent'
-
local_action
:
command util/elb_reg.py -e {{ ",".join(elbs[ansible_ec2_instance_id]) }} -i {{ ansible_ec2_instance_id }} deregister
# -e is the list of elbs that the current instances belong to and -i is
# the instance "active_elbs" are the elbs that are passed in.
roles
:
roles
:
-
common
-
common
-
nginx
-
nginx
-
lms
-
lms
#
- ruby
-
ruby
post_tasks
:
post_tasks
:
-
local_action
:
command util/elb_reg.py -e {{ ",".join(elbs[ansible_ec2_instance_id]) }} -i {{ ansible_ec2_instance_id }} register
-
name
:
Adding instance back to the ELB
# Register will pass in the same elb list and the same instance id
local_action
:
ec2_elb
# to add it back to the pool
args
:
instance_id
:
"
{{
ansible_ec2_instance_id
}}"
ec2_elbs
:
"
{{
ec2_elbs
}}"
state
:
'
present'
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment