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
Łukasz Nowak
slapos
Commits
bfcd51b8
Commit
bfcd51b8
authored
May 23, 2013
by
Cédric Le Ninivin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update publish recipe to work with slave instances
parent
927da9fb
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
4 deletions
+9
-4
slapos/recipe/publish.py
slapos/recipe/publish.py
+9
-4
No files found.
slapos/recipe/publish.py
View file @
bfcd51b8
...
@@ -32,17 +32,22 @@ CONNECTION_PARAMETER_STRING = 'connection-'
...
@@ -32,17 +32,22 @@ CONNECTION_PARAMETER_STRING = 'connection-'
class
Recipe
(
GenericSlapRecipe
):
class
Recipe
(
GenericSlapRecipe
):
def
_install
(
self
):
def
_install
(
self
):
slave_reference
=
None
publish_dict
=
dict
()
publish_dict
=
dict
()
options
=
self
.
options
.
copy
()
options
=
self
.
options
.
copy
()
del
options
[
'recipe'
]
del
options
[
'recipe'
]
if
'slave-reference'
in
options
:
slave_reference
=
options
[
'slave-reference'
]
for
k
,
v
in
options
.
iteritems
():
for
k
,
v
in
options
.
iteritems
():
publish_dict
[
k
]
=
v
publish_dict
[
k
]
=
v
self
.
_setConnectionDict
(
publish_dict
)
self
.
_setConnectionDict
(
publish_dict
,
slave_reference
)
return
[]
return
[]
def
_setConnectionDict
(
self
,
publish_dict
):
def
_setConnectionDict
(
self
,
publish_dict
,
slave_reference
=
None
):
if
slave_reference
is
None
:
return
self
.
setConnectionDict
(
publish_dict
)
return
self
.
setConnectionDict
(
publish_dict
)
else
:
return
self
.
setConnectionDict
(
publish_dict
,
slave_reference
)
SERIALISED_MAGIC_KEY
=
'_'
SERIALISED_MAGIC_KEY
=
'_'
...
...
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