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
1c247c9e
Commit
1c247c9e
authored
11 years ago
by
Johan Wirén
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated GenericBsdIfconfigNetwork to collect gateway
parent
714cb02f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
library/system/setup
+6
-3
No files found.
library/system/setup
View file @
1c247c9e
...
...
@@ -1548,9 +1548,12 @@ class GenericBsdIfconfigNetwork(Network):
lines
=
out
.
split
(
'
\n
'
)
for
line
in
lines
:
words
=
line
.
split
()
# look for first word starting interface
if
len
(
words
)
>
0
and
words
[
0
]
==
'interface:'
:
interface
[
v
][
'interface'
]
=
words
[
1
]
# Collect output from route command
if
len
(
words
)
>
0
:
if
words
[
0
]
==
'interface:'
:
interface
[
v
][
'interface'
]
=
words
[
1
]
if
words
[
0
]
==
'gateway:'
:
interface
[
v
][
'gateway'
]
=
words
[
1
]
return
interface
[
'v4'
],
interface
[
'v6'
]
...
...
This diff is collapsed.
Click to expand it.
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