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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Alain Takoudjou
slapos
Commits
5abd67a8
Commit
5abd67a8
authored
Feb 21, 2014
by
Nicolas Wavrant
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slaprunner: commit for deleting whitespaces
Conflicts: software/slaprunner/instance-runner.cfg
parent
4eee6031
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
32 additions
and
31 deletions
+32
-31
slapos/recipe/zeroknown.py
slapos/recipe/zeroknown.py
+7
-7
software/slaprunner/common.cfg
software/slaprunner/common.cfg
+3
-3
software/slaprunner/httpd_conf.in
software/slaprunner/httpd_conf.in
+1
-1
software/slaprunner/instance-runner.cfg
software/slaprunner/instance-runner.cfg
+10
-9
stack/monitor/monitor.cfg.in
stack/monitor/monitor.cfg.in
+4
-4
stack/monitor/monitor.py.in
stack/monitor/monitor.py.in
+5
-5
stack/monitor/webfiles/index.cgi.in
stack/monitor/webfiles/index.cgi.in
+1
-1
stack/monitor/webfiles/index.html.jinja2
stack/monitor/webfiles/index.html.jinja2
+1
-1
No files found.
slapos/recipe/zeroknown.py
View file @
5abd67a8
...
...
@@ -36,16 +36,16 @@ class WriteRecipe(GenericBaseRecipe):
"""
"""
def
__init__
(
self
,
buildout
,
name
,
options
):
if
not
"filename"
in
options
:
if
not
"filename"
in
options
:
raise
zc
.
buildout
.
UserError
(
"You have to provide the parameter
\
"
filename
\
"
"
)
self
.
filename
=
options
[
'filename'
].
strip
()
self
.
path
=
os
.
path
.
join
(
buildout
[
'buildout'
][
'directory'
],
self
.
filename
)
self
.
name
=
name
self
.
options
=
options
.
copy
()
del
self
.
options
[
'filename'
]
del
self
.
options
[
'recipe'
]
# Set up the parser, and write config file if needed
self
.
parser
=
ConfigParser
.
ConfigParser
()
try
:
...
...
@@ -63,7 +63,7 @@ class WriteRecipe(GenericBaseRecipe):
install
=
update
=
lambda
self
:
[]
def
full_install
(
self
):
"""XXX-Nicolas : when some parameter's value is changed in
"""XXX-Nicolas : when some parameter's value is changed in
buildout profile, this will override custom user defined values"""
self
.
parser
.
read
(
self
.
path
)
if
self
.
parser
.
has_section
(
self
.
name
):
...
...
@@ -74,14 +74,14 @@ class WriteRecipe(GenericBaseRecipe):
with
open
(
self
.
path
,
'w'
)
as
file
:
self
.
parser
.
write
(
file
)
class
ReadRecipe
(
GenericBaseRecipe
):
"""
"""
def
__init__
(
self
,
buildout
,
name
,
options
):
if
not
"filename"
in
options
:
if
not
"filename"
in
options
:
raise
zc
.
buildout
.
UserError
(
"You have to provide the parameter
\
"
filename
\
"
"
)
self
.
filename
=
options
[
'filename'
].
strip
()
self
.
path
=
os
.
path
.
join
(
buildout
[
'buildout'
][
'directory'
],
self
.
filename
)
...
...
software/slaprunner/common.cfg
View file @
5abd67a8
...
...
@@ -28,7 +28,7 @@ parts =
instance-runner-import
instance-runner-export
slapos-cookbook
slapos-cfg-template
slapos-cfg-template
# XXX: we have to manually add this for resilience
rdiff-backup
collective.recipe.template-egg
...
...
@@ -105,7 +105,7 @@ recipe = hexagonit.recipe.download
url = ${:_profile_base_location_}/template/${:filename}
md5sum = d31d1c51a51bc4b2b8dda197777a4bcb
location = ${buildout:parts-directory}/${:_buildout_section_name_}
filename = slapos.cfg.in
filename = slapos.cfg.in
download-only = true
mode = 0644
...
...
@@ -114,7 +114,7 @@ recipe = hexagonit.recipe.download
url = ${:_profile_base_location_}/${:filename}
md5sum = f8446fcf254b4929eb828a9a1d7e5f62
location = ${buildout:parts-directory}/${:_buildout_section_name_}
filename = parameters.xml.in
filename = parameters.xml.in
download-only = true
mode = 0644
...
...
software/slaprunner/httpd_conf.in
View file @
5abd67a8
...
...
@@ -73,4 +73,4 @@ RewriteRule ^/git-public/ - [E=AUTHREQUIRED:yes]
Require valid-user
</LocationMatch>
include {{ parameters.cgi_httpd_conf }}
include {{ parameters.cgi_httpd_conf }}
software/slaprunner/instance-runner.cfg
View file @
5abd67a8
...
...
@@ -163,7 +163,7 @@ runner_port = 50005
partition-amount = $${slap-parameter:instance-amount}
wrapper = $${directory:services}/slaprunner
debug = $${slap-parameter:debug}
access-url = https://[$${:ipv6}]:$${:runner_port}
access-url = https://[$${:ipv6}]:$${:runner_port}
supd-temp-var = $${directory:etc}/supervisord.conf
prox-db-var = $${slaprunner:working-directory}/proxy.db
console = False
...
...
@@ -305,13 +305,13 @@ cgi_httpd_conf = $${cgi-httpd-configuration-file:output}
recipe = slapos.recipe.template:jinja2
template = ${template_httpd_conf:location}/${template_httpd_conf:filename}
rendered = $${directory:etc}/httpd.conf
context =
context =
section parameters httpd-parameters
[cgi-httpd-wrapper]
recipe = slapos.cookbook:wrapper
apache-executable = ${apache:location}/bin/httpd
wrapper-path = $${ca-httpd:executable}
recipe = slapos.cookbook:wrapper
apache-executable = ${apache:location}/bin/httpd
wrapper-path = $${ca-httpd:executable}
command-line = $${:apache-executable} -f $${httpd-conf:rendered} -DFOREGROUND
#--------------------
...
...
@@ -503,8 +503,9 @@ context =
key runner_port slaprunner:runner_port
key runner_workdir slaprunner:working-directory
key slapgrid_cp slaprunner:slapgrid_cp
key slapgrid_sr slaprunner:slapgrid_sr
key slapproxy slaprunner:slapproxy
key slapgrid_sr slaprunner:slapgrid_sr
key slapproxy slaprunner:slapproxy
key software_root runnerdirectory:software-root
key ssh_client slaprunner:ssh_client
key supervisor slaprunner:supervisor
key supervisord_config slaprunner:supd-temp-var
...
...
@@ -516,7 +517,7 @@ ipv6 = $${slap-network-information:global-ipv6}
port = 8080
shell = $${shell:wrapper}
wrapper = $${directory:bin}/shellinaboxd
shellinabox-binary = ${shellinabox:location}/bin/shellinaboxd
shellinabox-binary = ${shellinabox:location}/bin/shellinaboxd
password = $${zero-parameters:shell-password}
directory = $${runnerdirectory:home}
login-shell = $${directory:bin}/login
...
...
@@ -571,7 +572,7 @@ extensions = jinja2.ext.do
template = ${parameters-template:location}/${parameters-template:filename}
rendered = $${directory:etc}/.parameter.xml.default
mode = 0644
context =
context =
key slapparameter_dict slap-configuration:configuration
[deploy-instance-parameters]
...
...
stack/monitor/monitor.cfg.in
View file @
5abd67a8
...
...
@@ -108,7 +108,7 @@ url = ${index-template:location}/$${:filename}
destination = $${directory:www}
filename = ${index-template:filename}
download-only = true
#md5sum =
#md5sum =
mode = 0644
[deploy-status-cgi]
...
...
@@ -144,7 +144,7 @@ context =
key monitoring_file_json monitor-parameters:json-path
key monitoring_folder_bool monitor-parameters:result-dir
raw python_executable ${buildout:executable}
[deploy-rss-script]
recipe = hexagonit.recipe.download
url = ${rss-bin:destination}/${rss-bin:filename}
...
...
@@ -158,7 +158,7 @@ download-only = true
recipe = slapos.recipe.template
url = ${make-rss-script:output}
output = $${directory:bin}/make-rss.sh
#md5sum =
#md5sum =
mode = 0744
[cadirectory]
...
...
@@ -235,7 +235,7 @@ input = inline:
SSLProtocol -ALL +SSLv3 +TLSv1
SSLHonorCipherOrder On
SSLCipherSuite RC4-SHA:HIGH:!ADH
</IfDefine>
</IfDefine>
SSLEngine On
ScriptSock $${:cgid-pid-file}
<Directory $${:document-root}>
...
...
stack/monitor/monitor.py.in
View file @
5abd67a8
...
...
@@ -67,7 +67,7 @@ def runScripts(directory):
command = [os.path.join(promise_dir, script)]
script = os.path.basename(command[0])
result[script] = ''
process_handler = subprocess.Popen(command,
cwd=instance_path,
env=None if sys.platform == 'cygwin' else {},
...
...
@@ -110,18 +110,18 @@ if __name__ == "__main__":
parser = OptionParser(option_list=option_list)
monitors = {}
(options, args) = parser.parse_args()
if not (options.monitor or options.promise
or options.service or options.all):
exit("Please provide at list one arg in : -a, -m, -p, -s")
if options.monitor or options.all:
monitors.update(runScripts(monitor_dir))
if options.promise or options.all:
monitors.update(runScripts(promise_dir))
if options.service or options.all:
monitors.update(runServices(pid_dir))
if options.only_stdout:
print json.dumps(monitors)
else:
...
...
@@ -130,4 +130,4 @@ if __name__ == "__main__":
exit(0)
else:
exit(1)
stack/monitor/webfiles/index.cgi.in
View file @
5abd67a8
...
...
@@ -51,7 +51,7 @@ def return_document():
def make_menu():
# Transform deep-2 tree in json
folder_list = {}
folder_list = {}
for folder in os.listdir(cgi_path):
if os.path.isdir(os.path.join(cgi_path, folder)):
folder_list[folder] = []
...
...
stack/monitor/webfiles/index.html.jinja2
View file @
5abd67a8
...
...
@@ -20,7 +20,7 @@
</ul>
</div>
</div>
<div
id=
"content"
>
<div
id=
"content"
>
<iframe
src=
"{{ default_page }}"
>
</iframe>
</div>
...
...
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