Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
ansible
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
ansible
Commits
eef05f7b
Commit
eef05f7b
authored
Jun 23, 2014
by
James Cammarata
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'botify-labs-bug/fix-health-check-to-zero-bug/7898' into devel
parents
ce41b023
9137679e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
1 deletions
+19
-1
library/cloud/ec2_asg
+19
-1
No files found.
library/cloud/ec2_asg
100644 → 100755
View file @
eef05f7b
...
...
@@ -73,6 +73,18 @@ options:
required: false
default: None
version_added: "1.7"
health_check_period:
description:
- Length of time in seconds after a new EC2 instance comes into service that Auto Scaling starts checking its health.
required: false
default: 500 seconds
version_added: "1.7"
health_check_type:
description:
- The service you want the health status from, Amazon EC2 or Elastic Load Balancer.
required: false
default: EC2
version_added: "1.7"
extends_documentation_fragment: aws
"""
...
...
@@ -141,6 +153,8 @@ def create_autoscaling_group(connection, module):
desired_capacity
=
module
.
params
.
get
(
'desired_capacity'
)
vpc_zone_identifier
=
module
.
params
.
get
(
'vpc_zone_identifier'
)
set_tags
=
module
.
params
.
get
(
'tags'
)
health_check_period
=
module
.
params
.
get
(
'health_check_period'
)
health_check_type
=
module
.
params
.
get
(
'health_check_type'
)
as_groups
=
connection
.
get_all_groups
(
names
=
[
group_name
])
...
...
@@ -173,7 +187,9 @@ def create_autoscaling_group(connection, module):
desired_capacity
=
desired_capacity
,
vpc_zone_identifier
=
vpc_zone_identifier
,
connection
=
connection
,
tags
=
asg_tags
)
tags
=
asg_tags
,
health_check_period
=
health_check_period
,
health_check_type
=
health_check_type
)
try
:
connection
.
create_auto_scaling_group
(
ag
)
...
...
@@ -272,6 +288,8 @@ def main():
vpc_zone_identifier
=
dict
(
type
=
'str'
),
state
=
dict
(
default
=
'present'
,
choices
=
[
'present'
,
'absent'
]),
tags
=
dict
(
type
=
'list'
,
default
=
[]),
health_check_period
=
dict
(
type
=
'int'
,
default
=
300
),
health_check_type
=
dict
(
default
=
'EC2'
,
chices
=
[
'EC2'
,
'ELB'
]),
)
)
module
=
AnsibleModule
(
argument_spec
=
argument_spec
)
...
...
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