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
bfa71054
Commit
bfa71054
authored
Jan 03, 2015
by
Milamber
Committed by
Rene Moser
Apr 28, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix an issue when the cloudstack installation don't have any instance group
parent
92a25b34
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
plugins/inventory/cloudstack.py
+7
-6
No files found.
plugins/inventory/cloudstack.py
View file @
bfa71054
...
@@ -173,12 +173,13 @@ class CloudStackInventory(object):
...
@@ -173,12 +173,13 @@ class CloudStackInventory(object):
}
}
groups
=
self
.
cs
.
listInstanceGroups
(
projectid
=
project_id
)
groups
=
self
.
cs
.
listInstanceGroups
(
projectid
=
project_id
)
for
group
in
groups
[
'instancegroup'
]:
if
groups
:
group_name
=
group
[
'name'
]
for
group
in
groups
[
'instancegroup'
]:
if
group_name
and
not
group_name
in
data
:
group_name
=
group
[
'name'
]
data
[
group_name
]
=
{
if
group_name
and
not
group_name
in
data
:
'hosts'
:
[]
data
[
group_name
]
=
{
}
'hosts'
:
[]
}
hosts
=
self
.
cs
.
listVirtualMachines
(
projectid
=
project_id
)
hosts
=
self
.
cs
.
listVirtualMachines
(
projectid
=
project_id
)
for
host
in
hosts
[
'virtualmachine'
]:
for
host
in
hosts
[
'virtualmachine'
]:
...
...
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