Commit 4ef9c28f authored by Łukasz Nowak's avatar Łukasz Nowak

Merge haproxy into snippet-backend

parent e56d72af
#############################
#
# Instanciate haproxy
#
# haproxy-id -- local id of the requested haproxy (login, web,...)
#
# haproxy-port -- ip port to use to run the process
#
# maxconn -- max connection per server
#
# site-id -- ID of the ERP5 site object in ZODB
#
# storage_list -- string with list of all resquested storage
# Example: event_module person_module
#
#############################
[buildout]
parts =
haproxy-instance
publish-haproxy-connection-information
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
offline = true
[rootdirectory]
recipe = slapos.cookbook:mkdirectory
etc = $${buildout:directory}/etc/
[basedirectory]
recipe = slapos.cookbook:mkdirectory
services = $${rootdirectory:etc}/run/
[haproxy-instance]
recipe = slapos.cookbook:haproxy
name = $${slap-parameter:haproxy-id}
conf-path = $${rootdirectory:etc}/haproxy-$${slap-parameter:haproxy-id}.cfg
ip = $${slap-network-information:local-ipv4}
port = $${slap-parameter:haproxy-port}
maxconn = $${slap-parameter:maxconn}
server-check-path = /$${slap-parameter:site-id}/getId
wrapper-path = $${basedirectory:services}/haproxy_$${slap-parameter:haproxy-id}
binary-path = ${memcached:location}/bin/memcached
[publish-haproxy-connection-information]
recipe = slapos.cookbook:publishurl
url = http://$${haproxy-instance:ip}:$${haproxy-instance:port}/
......@@ -76,7 +76,6 @@ memcached = ${template-memcached:output}
cloudooo = ${template-cloudooo:output}
zope = ${template-zope:output}
mariadb = ${template-mariadb:output}
haproxy = ${template-haproxy:output}
tidstorage = $${dynamic-template-tidstorage:output}
[slap-connection]
......
......@@ -33,3 +33,16 @@ post = ${buildout:bin-directory}/killpidfromfile $${apache-zope-backend-instance
sharedscripts = true
notifempty = true
create = true
[haproxy-instance]
recipe = slapos.cookbook:haproxy
name = $${slap-parameter:haproxy-id}
conf-path = $${rootdirectory:etc}/haproxy-$${slap-parameter:haproxy-id}.cfg
ip = $${slap-network-information:local-ipv4}
port = $${slap-parameter:haproxy-port}
maxconn = $${slap-parameter:maxconn}
server-check-path = /$${slap-parameter:site-id}/getId
wrapper-path = $${basedirectory:services}/haproxy_$${slap-parameter:haproxy-id}
binary-path = ${memcached:location}/bin/memcached
......@@ -12,7 +12,6 @@ parts +=
template-cloudooo
template-zope
template-mariadb
template-haproxy
template
validator
......@@ -49,13 +48,6 @@ md5sum = d8a4a1976f4d22fae0668be0543438cc
output = ${buildout:directory}/template-kumofs.cfg
mode = 0644
[template-haproxy]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-haproxy.cfg
md5sum = ba2b358bc65c69533761fef8662cca30
output = ${buildout:directory}/template-haproxy.cfg
mode = 0644
[instance-recipe]
# Note: In case if specific instantiation recipe is used this is the place to
# put its name
......@@ -68,7 +60,7 @@ configurator_bt5_list = erp5_core_proxy_field_legacy erp5_full_text_myisam_catal
[template]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance.cfg
md5sum = 2ad8b538cb3c812f497cdba7116d0d6a
md5sum = 52f3c27de3e9e5f9223084829c3ed2f6
output = ${buildout:directory}/template.cfg
mode = 0644
......@@ -110,7 +102,7 @@ mode = 0644
[template-snippet-backend]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/snippet-backend.cfg
md5sum = 8105ea278fc00549a4f5a12eba14cae0
md5sum = 50963d43711c1f928841b844d38b7286
output = ${buildout:directory}/template-snippet-backend.cfg
mode = 0644
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment