Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
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
5
Merge Requests
5
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jérome Perrin
slapos
Commits
e4913317
Commit
e4913317
authored
Jun 19, 2013
by
Benjamin Blanc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
UP
parent
f1183441
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
167 additions
and
1 deletion
+167
-1
slapos/recipe/generic_scalability_launcher/__init__.py
slapos/recipe/generic_scalability_launcher/__init__.py
+48
-0
slapos/recipe/generic_scalability_launcher/template/launcher.in
.../recipe/generic_scalability_launcher/template/launcher.in
+2
-0
stack/erp5/buildout.cfg
stack/erp5/buildout.cfg
+7
-1
stack/erp5/instance-scalability-launcher.cfg.in
stack/erp5/instance-scalability-launcher.cfg.in
+38
-0
stack/erp5/instance-scalability.cfg.in
stack/erp5/instance-scalability.cfg.in
+58
-0
stack/erp5/instance.cfg.in
stack/erp5/instance.cfg.in
+14
-0
No files found.
slapos/recipe/generic_scalability_launcher/__init__.py
0 → 100644
View file @
e4913317
##############################################################################
#
# Copyright (c) 2011 Vifib SARL and Contributors. All Rights Reserved.
#
# WARNING: This program as such is intended to be used by professional
# programmers who take the whole responsibility of assessing all potential
# consequences resulting from its eventual inadequacies and bugs
# End users who are looking for a ready-to-use solution with commercial
# guarantees and support are strongly adviced to contract a Free Software
# Service Company
#
# This program is Free Software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
##############################################################################
import
os
from
slapos.recipe.librecipe
import
GenericBaseRecipe
class
Recipe
(
GenericBaseRecipe
):
def
install
(
self
):
# Var passed to template
config
=
dict
(
url
=
self
.
options
[
'url'
],
scalability_launcher_log
=
self
.
options
[
'scalability-launcher-log'
],
scalability_launcher_binary
=
self
.
options
[
'scalability-launcher-binary'
],
test_suite_title
=
self
.
options
[
'test-suite-title'
],
shell_path
=
self
.
options
[
'shell-path'
],
)
# Executable creation and return the path
path_list
=
[]
path_list
.
append
(
self
.
createExecutable
(
self
.
options
[
'scalability-launcher-wrapper'
],
self
.
substituteTemplate
(
self
.
getTemplateFilename
(
'launcher.in'
),
config
)))
return
path_list
slapos/recipe/generic_scalability_launcher/template/launcher.in
0 → 100644
View file @
e4913317
#!%(shell_path)s
exec %(scalability_launcher_binary)s %(url)s 5 %(test_suite_title)s %(scalability_launcher_log)s
\ No newline at end of file
stack/erp5/buildout.cfg
View file @
e4913317
...
...
@@ -146,7 +146,7 @@ mode = 644
[slapos.cookbook-repository]
recipe = slapos.recipe.build:gitclone
repository = http://git.erp5.org/repos/slapos.git
branch = erp5-cluster-z2.13
branch = erp5-cluster-z2.13
-scalability
git-executable = ${git:location}/bin/git
[check-recipe]
...
...
@@ -267,6 +267,7 @@ extra-context =
key template_cluster_zope template-cluster-zope:target
key template_erp5_single template-erp5-single:target
key template_erp5_cluster template-erp5-cluster:target
key template_scalability template-scalability:target
key template_kumofs template-kumofs:target
key template_logrotate_base template-logrotate-base:rendered
key template_mariadb template-mariadb:target
...
...
@@ -293,6 +294,11 @@ md5sum = 69961d8b60ce529baaf958dc76537ac5
filename = instance-erp5-cluster.cfg.in
md5sum = d4d95f1749e1d9d3701565f934fcd4dc
[template-scalability]
< = download-base
filename = instance-scalability.cfg.in
md5sum = xxxxxxxxxxxxxxxxxxxxxxxxxx
[template-zeo]
< = download-base
filename = instance-zeo.cfg.in
...
...
stack/erp5/instance-scalability-launcher.cfg.in
0 → 100644
View file @
e4913317
{% if software_type == slap_software_type -%}
[buildout]
parts =
scalability-launcher-instance
eggs-directory = {{ eggs_directory }}
develop-eggs-directory = {{ develop_eggs_directory }}
offline = true
[scalability-launcher-instance]
recipe = slapos.cookbook:generic.scalability_launcher
#
# maybe be change this variable name
# just need to know test_result url ?
url = "http://foo.bar"
# the suite to launch (?)
test-suite-title = "ERP5-Sca"
# Paths: Running wrappers
scalability-launcher-wrapper = ${basedirectory:services}/scalability_launcher
# Paths: Logs
scalability-launcher-log = ${basedirectory:log}/scalability_launcher.log
# Binary information
scalability-launcher-binary = {{ parameter_dict['scalability-location'] }}/bin/scalability_launcher
shell-path = {{ parameter_dict['dash-location'] }}/bin/dash
# Directory creation
[basedirectory]
recipe = slapos.cookbook:mkdirectory
log = ${rootdirectory:var}/log
run = ${rootdirectory:var}/run
services = ${rootdirectory:etc}/run
[rootdirectory]
recipe = slapos.cookbook:mkdirectory
etc = ${buildout:directory}/etc
var = ${buildout:directory}/var
srv = ${buildout:directory}/srv
bin = ${buildout:directory}/bin
\ No newline at end of file
stack/erp5/instance-scalability.cfg.in
0 → 100644
View file @
e4913317
{% if slap_software_type == software_type -%}
[request-common]
recipe = slapos.cookbook:request.serialised
software-url = ${slap-connection:software-release-url}
sla = computer_guid
return = url
server-url = ${slap-connection:server-url}
key-file = ${slap-connection:key-file}
cert-file = ${slap-connection:cert-file}
computer-id = ${slap-connection:computer-id}
partition-id = ${slap-connection:partition-id}
config =
use-ipv6
${:extra-config}
extra-config =
config-use-ipv6 = {{ dumps(slapparameter_dict.get('use-ipv6', False)) }}
[request-erp5-cluster]
<=request-common
name = ERP5 Cluster
software-type = cluster
[request-launcher-base]
<=request-common
return =
extra-config =
[request-scalability-launcher-1]
< = request-launcher-base
name = scalability-launcher-1
sla-computer_guid = {{ slapparameter_dict.get('scalability-launcher-computer-guid') }}
# Generate launcher instance requests
#{% for comp_name in slapparameter_dict.get('launcher-partition-dict', {'1': {}}) -%}
#{% set base_name = 'scalability-launcher-' ~ comp_name -%}
#{% set name = 'request-' ~ base_name -%}
#[{{ name }}]
#< = request-launcher-base
#name = {{ base_name }}
#sla-computer_guid = {{ comp_name }}
#{% endfor -%}
[publish]
recipe = slapos.cookbook:publish.serialised
{% for family_name, publishable in publish_dict.items() -%}
{{ family_name }} = {{ '${' ~ publishable ~ '}' }}
{% endfor -%}
[buildout]
parts = publish
eggs-directory = {{ eggs_directory }}
develop-eggs-directory = {{ develop_eggs_directory }}
offline = true
{% endif %}
stack/erp5/instance.cfg.in
View file @
e4913317
...
...
@@ -164,6 +164,19 @@ extra-context =
# Must match the key id in [switch-softwaretype] which uses this section.
raw software_type cluster
[dynamic-template-scalability-parameters]
local-bt5-repository = {{ local_bt5_repository }}
[dynamic-template-scalability]
< = jinja2-template-base
template = {{ template_scalability }}
filename = instance-scalability.cfg
extensions = jinja2.ext.do
extra-context =
key local_bt5_repository dynamic-template-scalability-parameters:local-bt5-repository
# Must match the key id in [switch-softwaretype] which uses this section.
raw software_type scalability
[dynamic-template-balancer-parameters]
apache = {{ apache_location }}
openssl = {{ openssl_location }}
...
...
@@ -274,6 +287,7 @@ extra-context =
recipe = slapos.cookbook:softwaretype
default = ${template-erp5-single:rendered}
cluster = ${dynamic-template-cluster-erp5:rendered}
scalability = ${dynamic-template-scalability:rendered}
kumofs = ${dynamic-template-kumofs:rendered}
cloudooo = ${dynamic-template-cloudooo:rendered}
zope = ${dynamic-template-zope:rendered}
...
...
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