Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dmitry Blinov
slapos
Commits
c6fb9e8c
Commit
c6fb9e8c
authored
Jan 07, 2013
by
Marco Mariani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
also provide single ip values
parent
33142459
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
0 deletions
+11
-0
slapos/recipe/slapconfiguration.py
slapos/recipe/slapconfiguration.py
+11
-0
No files found.
slapos/recipe/slapconfiguration.py
View file @
c6fb9e8c
...
...
@@ -64,6 +64,10 @@ class Recipe(object):
Set of IPv4 addresses.
ipv6
Set of IPv6 addresses.
ipv4_random
One of the IPv4 addresses.
ipv6_random
One of the IPv6 addresses.
tap
Set of TAP interfaces.
configuration
...
...
@@ -109,6 +113,13 @@ class Recipe(object):
# XXX: emit warning on unknown address type ?
options
[
'ipv4'
]
=
ipv4_set
options
[
'ipv6'
]
=
ipv6_set
# also export single ip values for those recipes that don't support sets.
if
ipv4_set
:
options
[
'ipv4_random'
]
=
list
(
ipv4_set
)[
0
]
if
ipv6_set
:
options
[
'ipv6_random'
]
=
list
(
ipv6_set
)[
0
]
options
[
'tap'
]
=
tap_set
options
[
'configuration'
]
=
parameter_dict
match
=
self
.
OPTCRE_match
...
...
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