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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
iv
slapos
Commits
5a60ad67
Commit
5a60ad67
authored
Sep 12, 2015
by
Alain Takoudjou
Committed by
Tristan Cavelier
Oct 07, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
monitor: write service parameters in run folder
parent
4c295942
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
stack/monitor/buildout.cfg
stack/monitor/buildout.cfg
+1
-1
stack/monitor/templates/monitor-service-run.in
stack/monitor/templates/monitor-service-run.in
+2
-2
No files found.
stack/monitor/buildout.cfg
View file @
5a60ad67
...
...
@@ -87,7 +87,7 @@ mode = 0644
recipe = hexagonit.recipe.download
url = ${:_profile_base_location_}/templates/${:filename}
download-only = true
md5sum =
eac72b9a452a1fb0a955c7cebb2d3c23
md5sum =
d5f29fa859a45696e1ff1bb174ab1111
filename = monitor-service-run.in
mode = 0644
...
...
stack/monitor/templates/monitor-service-run.in
View file @
5a60ad67
...
...
@@ -16,11 +16,11 @@ def loadConfig(config_file):
def
main
():
config
=
loadConfig
(
configuration_location
)
exec_env
=
os
.
environ
.
copy
()
script_path
=
config
.
get
(
"service"
,
"script-path"
)
executable_folder
=
os
.
path
.
dirname
(
script_path
)
executable
=
os
.
path
.
basename
(
script_path
)
parameter_json
=
os
.
path
.
join
(
os
.
getcwd
(),
'parameters.json'
)
parameter_json
=
os
.
path
.
join
(
os
.
path
.
abspath
(
os
.
path
.
dirname
(
__file__
)),
'parameters_%%s.json'
%%
executable
)
with
open
(
parameter_json
,
'w'
)
as
fjson
:
fjson
.
write
(
json
.
dumps
(
dict
(
config
.
items
(
"parameter"
))))
...
...
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