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
227e8e31
Commit
227e8e31
authored
Jan 04, 2014
by
Michael DeHaan
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'use_comps' of
git://github.com/j2sol/ansible
into devel
parents
10350d16
23720ff1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
8 deletions
+2
-8
lib/ansible/inventory/__init__.py
+2
-8
No files found.
lib/ansible/inventory/__init__.py
View file @
227e8e31
...
...
@@ -133,11 +133,7 @@ class Inventory(object):
# exclude hosts not in a subset, if defined
if
self
.
_subset
:
subset
=
self
.
_get_hosts
(
self
.
_subset
)
new_hosts
=
[]
for
h
in
hosts
:
if
h
in
subset
and
h
not
in
new_hosts
:
new_hosts
.
append
(
h
)
hosts
=
new_hosts
hosts
=
[
h
for
h
in
hosts
if
h
in
subset
]
# exclude hosts mentioned in any restriction (ex: failed hosts)
if
self
.
_restriction
is
not
None
:
...
...
@@ -183,9 +179,7 @@ class Inventory(object):
elif
p
.
startswith
(
"&"
):
hosts
=
[
h
for
h
in
hosts
if
h
in
that
]
else
:
for
h
in
that
:
if
h
not
in
hosts
:
hosts
.
append
(
h
)
hosts
.
extend
([
h
for
h
in
that
if
h
not
in
hosts
])
return
hosts
...
...
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