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
edx
configuration
Commits
a6aa82ad
Commit
a6aa82ad
authored
Aug 06, 2015
by
Max Rothman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix ec2_lookup so it follows the tag format it says it does (backwards compatable)
parent
1c583f26
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
4 deletions
+11
-4
playbooks/library/ec2_lookup
+11
-4
No files found.
playbooks/library/ec2_lookup
View file @
a6aa82ad
...
...
@@ -96,14 +96,21 @@ def main():
aws_secret_key
=
dict
(
aliases
=
[
'ec2_secret_key'
,
'secret_key'
],
no_log
=
True
),
aws_access_key
=
dict
(
aliases
=
[
'ec2_access_key'
,
'access_key'
]),
tags
=
dict
(
default
=
None
,
type
=
'list'
),
tags
=
dict
(
default
=
None
),
)
)
tags_param
=
module
.
params
.
get
(
'tags'
)
tags
=
{}
for
item
in
module
.
params
.
get
(
'tags'
):
for
k
,
v
in
item
.
iteritems
():
tags
[
k
]
=
v
if
isinstance
(
tags_param
,
list
):
for
item
in
module
.
params
.
get
(
'tags'
):
for
k
,
v
in
item
.
iteritems
():
tags
[
k
]
=
v
elif
isinstance
(
tags_param
,
dict
):
tags
=
tags_param
else
:
module
.
fail_json
(
msg
=
"Invalid format for tags"
)
aws_secret_key
=
module
.
params
.
get
(
'aws_secret_key'
)
aws_access_key
=
module
.
params
.
get
(
'aws_access_key'
)
...
...
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