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
59869595
Commit
59869595
authored
May 23, 2014
by
AJ Bourg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove some development code. EC2 -> SoftLayer
parent
79f2dca6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
plugins/inventory/softlayer.py
+3
-5
No files found.
plugins/inventory/softlayer.py
View file @
59869595
...
...
@@ -72,7 +72,7 @@ class SoftLayerInventory(object):
def
parse_options
(
self
):
'''Parse all the arguments from the CLI'''
parser
=
argparse
.
ArgumentParser
(
description
=
'Produce an Ansible Inventory file based on
EC2
'
)
parser
=
argparse
.
ArgumentParser
(
description
=
'Produce an Ansible Inventory file based on
SoftLayer
'
)
parser
.
add_argument
(
'--list'
,
action
=
'store_true'
,
default
=
False
,
help
=
'List instances (default: False)'
)
parser
.
add_argument
(
'--host'
,
action
=
'store'
,
...
...
@@ -103,9 +103,8 @@ class SoftLayerInventory(object):
if
'hardwareStatusId'
in
instance
and
instance
[
'hardwareStatusId'
]
!=
5
:
return
# if there's no IP address, we can't reach it
if
'primaryIpAddress'
not
in
instance
:
print
instance
[
'fullyQualifiedDomainName'
]
+
" doesn't have an ip!"
print
instance
return
dest
=
instance
[
'primaryIpAddress'
]
...
...
@@ -160,4 +159,4 @@ class SoftLayerInventory(object):
self
.
get_virtual_servers
()
self
.
get_physical_servers
()
SoftLayerInventory
()
\ No newline at end of file
SoftLayerInventory
()
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