Commit 24a91de4 authored by Vincent Pelletier's avatar Vincent Pelletier

Get rid of unused/unsupported software type.

Drop instance-erp5-single and instance-zope:
All deployments of ERP5 instances must be covered by cluster-style
deployment, and tweaked by parameters rather than software type.
Drop instance-varnish:
This is not used currently, so avoid giving the impression that it is
supported. Revive when properly integrated.
parent 37fc1ffa
......@@ -50,7 +50,6 @@ extends =
../../component/stunnel/buildout.cfg
../../component/subversion/buildout.cfg
../../component/tesseract/buildout.cfg
../../component/varnish/buildout.cfg
../../component/w3-validator/buildout.cfg
../../component/w3m/buildout.cfg
../../component/xorg/buildout.cfg
......@@ -79,7 +78,6 @@ parts =
haproxy
jsl
stunnel
varnish-3.0
w3m
poppler
libpng
......@@ -175,11 +173,6 @@ context =
filename = instance-mariadb.cfg.in
md5sum = 2d3bc3bb5e79519897c96acbdcc4ece6
[template-zope]
< = download-base
filename = instance-zope.cfg.in
md5sum = 2b68521ebde309d6453336f1a2e46381
[template-kumofs]
< = download-base
filename = instance-kumofs.cfg.in
......@@ -210,7 +203,7 @@ md5sum = 564006953b7d7a12d40a14b6648b32f0
# XXX: "template.cfg" is hardcoded in instanciation recipe
filename = template.cfg
template = ${:_profile_base_location_}/instance.cfg.in
md5sum = 3465c19d25e14865c6e844c9a26ee984
md5sum = d2b0f35e82bb0967fef99b3b7d37768e
extra-context =
key apache_location apache:location
key aspell_location aspell:location
......@@ -258,34 +251,25 @@ extra-context =
key stunnel_location stunnel:location
key template_balancer template-balancer:target
key template_cloudooo template-cloudooo:target
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_erp5 template-erp5:target
key template_kumofs template-kumofs:target
key template_logrotate_base template-logrotate-base:rendered
key template_mariadb template-mariadb:target
key template_mariadb_initial_setup template-mariadb-initial-setup:target
key template_my_cnf template-my-cnf:target
key template_neo template-neo:target
key template_varnish template-varnish:target
key template_zeo template-zeo:target
key template_zope template-zope:target
key template_zope_conf template-zope-conf:target
key tesseract_location tesseract:location
key varnish_location varnish-3.0:location
key w3m_location w3m:location
key wget_location wget:location
key zlib_location zlib:location
[template-erp5-single]
< = download-base
filename = instance-erp5-single.cfg.in
md5sum = 77ec4f095a22b5bd7dfea9dff63bade5
[template-erp5-cluster]
[template-erp5]
< = download-base
filename = instance-erp5-cluster.cfg.in
md5sum = c745d794b28cae64feba527f894d7340
md5sum = 4a0cd404bed41a58512396af9f964c66
[template-neo]
< = download-base
......@@ -297,7 +281,7 @@ md5sum = 1499c42d196f6627efb904f7e4d48b1b
filename = instance-zeo.cfg.in
md5sum = 9fff70e6958bccbb3d4982cb3611813f
[template-cluster-zope]
[template-zope]
< = download-base
filename = instance-cluster-zope.cfg.in
md5sum = c5c13fb438aa2a4d9ce22880e16fc2cd
......@@ -316,11 +300,6 @@ extra-context =
key gzip_location gzip:location
key logrotate_location logrotate:location
[template-varnish]
< = download-base
filename = instance-varnish.cfg.in
md5sum = b3020e1da069d43ece0de99b106cfb45
[bt5-repository]
# Format:
# <url or path> [...]
......
......@@ -81,7 +81,7 @@ config-tidstorage-ip = ${request-zodb:connection-tidstorage-ip}
config-tidstorage-port = ${request-zodb:connection-tidstorage-port}
config-timezone = {{ slapparameter_dict.get('timezone', 'UTC') }}
config-site-id = {{ site_id }}
software-type = cluster-zope
software-type = zope
{% set zope_family_dict = {} -%}
{% for custom_name, zope_parameter_dict in slapparameter_dict.get('zope-partition-dict', {'1': {}}).items() -%}
......
#############################
#
# Request erp5 development environnment
#
#############################
[buildout]
extends = {{ template_zope }}
parts +=
request-mariadb
request-cloudooo
request-memcached
request-kumofs
basedirectory
test-runner
erp5-bootstrap
erp5-promise
promise-erp5-site
eggs-directory = {{ eggs_directory }}
develop-eggs-directory = {{ develop_eggs_directory }}
offline = true
[slap-parameter]
# default site id
site-id = erp5
cloudooo-json =
promise-path = ${rootdirectory:etc}/erp5promise.cfg
bt5 = erp5_full_text_myisam_catalog
erp5_configurator_standard
erp5_configurator_maxma_demo
erp5_configurator_ung
erp5_configurator_run_my_doc
bt5-repository-url = {{ local_bt5_repository }}
smtp-url = smtp://localhost:25/
[test-runner]
recipe = slapos.cookbook:erp5.test
certificate-authority-path = ${test-certificate-authority:ca-dir}
mysql-url = ${request-mariadb:connection-url}
kumofs-url = ${request-kumofs:connection-url}
memcached-url = ${request-memcached:connection-url}
cloudooo-url = ${request-cloudooo:connection-url}
test-instance-path = ${directory:unit-test-path}
prepend-path = ${buildout:bin-directory}
run-unit-test = ${buildout:bin-directory}/runUnitTest
run-test-suite = ${buildout:bin-directory}/runTestSuite
openssl-binary = ${test-certificate-authority:openssl-binary}
run-unit-test-binary = {{ bin_directory }}/runUnitTest
run-test-suite-binary = {{ bin_directory }}/runTestSuite
[test-certificate-authority]
recipe = slapos.cookbook:certificate_authority
openssl-binary = {{ openssl_location }}/bin/openssl
ca-dir = ${directory:test-ca-dir}
requests-directory = ${test-cadirectory:requests}
wrapper = ${basedirectory:services}/test-ca
ca-private = ${test-cadirectory:private}
ca-certs = ${test-cadirectory:certs}
ca-newcerts = ${test-cadirectory:newcerts}
ca-crl = ${test-cadirectory:crl}
[test-cadirectory]
recipe = slapos.cookbook:mkdirectory
requests = ${directory:test-ca-dir}/requests
private = ${directory:test-ca-dir}/private
certs = ${directory:test-ca-dir}/certs
newcerts = ${directory:test-ca-dir}/newcerts
crl = ${directory:test-ca-dir}/crl
[erp5-bootstrap]
recipe = slapos.cookbook:erp5.bootstrap
runner-path = ${basedirectory:services}/erp5-bootstrap
mysql-url = ${request-mariadb:connection-url}
zope-url = http://${zope-instance:user}:${zope-instance:password}@${zope-instance:ip}:${zope-instance:port}/${slap-parameter:site-id}
[erp5-promise]
recipe = slapos.cookbook:erp5.promise
promise-path = ${slap-parameter:promise-path}
kumofs-url = ${request-kumofs:connection-url}
memcached-url = ${request-memcached:connection-url}
cloudooo-url = ${request-cloudooo:connection-url}
smtp-url = ${slap-parameter:smtp-url}
bt5 = ${slap-parameter:bt5}
bt5-repository-url = ${slap-parameter:bt5-repository-url}
[request-common]
recipe = slapos.cookbook:request.serialised
software-url = ${slap-connection:software-release-url}
sla = computer_guid
sla-computer_guid = ${slap-connection:computer-id}
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}
[request-mariadb]
<=request-common
name = MariaDB DataBase
software-type = mariadb
{% set mariadb_dict = slapparameter_dict.get('mariadb-dict', {}) -%}
{% for option, value in mariadb_dict.items() -%}
config-{{ option }} = {{ dumps(value) }}
{% endfor -%}
config = {{ ' '.join(mariadb_dict) }}
[request-cloudooo]
<=request-common
name = Cloudooo
config = cloudooo-json
config-cloudooo-json = ${slap-parameter:cloudooo-json}
software-type = cloudooo
[request-memcached]
<=request-common
name = KumoFS-ram
software-type = kumofs
config = ram-storage-size
config-ram-storage-size = 64m
[request-kumofs]
<=request-common
name = KumoFS
software-type = kumofs
[zope-instance]
promise-path = ${slap-parameter:promise-path}
site-id = ${slap-parameter:site-id}
[directory]
test-ca-dir = ${rootdirectory:srv}/test-ca
test-instance-path = ${rootdirectory:srv}/test-instance
unit-test-path = ${:test-instance-path}/unit_test
[promise-erp5-site]
recipe = slapos.cookbook:check_url_available
path = ${basedirectory:promises}/erp5site
url = http://${zope-instance:ip}:${zope-instance:port}/${slap-parameter:site-id}
dash_path = {{ dash_location }}/bin/dash
curl_path = {{ curl_location }}/bin/curl
{% if software_type == slap_software_type -%}
{% set web_checker_parameter = slapparameter_dict['web-checker-mail-address'] -%}
[buildout]
parts =
publish-varnish-connection-information
varnish-instance
cron
cron-entry-logrotate
{# When web_checker related parameter is given, web_checker will be enabled.#}
{% if web_checker_parameter is defined %}
web-checker
cron-entry-web-checker
logrotate-entry-web-checker
{% endif %}
eggs-directory = {{ eggs_directory }}
develop-eggs-directory = {{ develop_eggs_directory }}
offline = true
[publish-varnish-connection-information]
recipe = slapos.cookbook:publish.serialised
url = http://${varnish-instance:ip}:${varnish-instance:server-port}/
[varnish-instance]
recipe = slapos.cookbook:generic.varnish
# Network options
ip = ${slap-network-information:local-ipv4}
server-port = 6001
manager-port = 6002
stunnel-port = 6003
# Paths: Running wrappers
varnishd-wrapper = ${basedirectory:services}/varnishd
varnishlog-wrapper = ${rootdirectory:bin}/varnishlog
stunnel-wrapper = ${basedirectory:services}/stunnel
# Binary information
varnishd-binary = {{ parameter_dict['varnish'] }}/sbin/varnishd
varnishlog-binary = {{ parameter_dict['varnish'] }}/bin/varnishlog
shell-path = {{ parameter_dict['dash'] }}/bin/dash
stunnel-binary = {{ parameter_dict['stunnel'] }}/bin/stunnel
# Configuration by VCL
vcl-file = ${rootdirectory:etc}/default.vcl
pid-file = ${basedirectory:run}/varnishd.pid
stunnel-conf-file = ${rootdirectory:etc}/stunnel.conf
stunnel-pid-file = ${basedirectory:run}/stunnel.pid
varnish-data = ${directory:varnish-data}
# this will pass at -n option
varnish-instance-name = ${directory:varnish-instance}
web-checker = {{ parameter_dict['buildout-bin-directory'] }}/web_checker_utility
[cron-entry-web-checker]
<= cron
recipe = slapos.cookbook:cron.d
name = web-checker
frequency = 0 0 * * *
command = ${varnish-instance:web-checker} ${web-checker:web-checker-config}
[web-checker]
recipe = slapos.cookbook:webchecker
web-checker-config = ${rootdirectory:etc}/web_checker.cfg
web-checker-working-directory = ${directory:web-checker}
frontend-url = ${varnish-instance:ip}:${varnish-instance:server-port}
wget-binary-path = {{ parameter_dict['wget'] }}/bin/wget
varnishlog-binary-path = ${varnish-instance:varnishlog-wrapper}
web-checker-log = ${basedirectory:log}/web-checker.log
[cron]
recipe = slapos.cookbook:cron
dcrond-binary = {{ parameter_dict['dcron'] }}/sbin/crond
cron-entries = ${directory:cron-entries}
crontabs = ${directory:crontabs}
cronstamps = ${directory:cronstamps}
binary = ${basedirectory:services}/crond
catcher = ${cron-simplelogger:wrapper}
[cron-simplelogger]
recipe = slapos.cookbook:simplelogger
wrapper = ${rootdirectory:bin}/cron_simplelogger
log = ${basedirectory:log}/cron.log
[cron-entry-logrotate]
<= cron
recipe = slapos.cookbook:cron.d
name = logrotate
frequency = 0 0 * * *
command = ${logrotate:wrapper}
[logrotate]
recipe = slapos.cookbook:logrotate
# Binaries
logrotate-binary = {{ parameter_dict['logrotate'] }}/usr/sbin/logrotate
gzip-binary = {{ parameter_dict['gzip'] }}/bin/gzip
gunzip-binary = {{ parameter_dict['gzip'] }}/bin/gunzip
# Directories
wrapper = ${rootdirectory:bin}/logrotate
conf = ${rootdirectory:etc}/logrotate.conf
logrotate-entries = ${directory:logrotate-entries}
backup = ${directory:logrotate-backup}
state-file = ${rootdirectory:srv}/logrotate.status
[logrotate-entry-web-checker]
<= logrotate
recipe = slapos.cookbook:logrotate.d
name = web-checker
log = ${web-checker:web-checker-log}
frequency = daily
rotate-num = 30
sharedscripts = true
notifempty = true
create = true
[basedirectory]
recipe = slapos.cookbook:mkdirectory
services = ${rootdirectory:etc}/run
run = ${rootdirectory:var}/run
backup = ${rootdirectory:srv}/backup
log = ${rootdirectory:var}/log
backup = ${rootdirectory:srv}/backup
[directory]
recipe = slapos.cookbook:mkdirectory
varnish-data = ${rootdirectory:srv}/varnish
varnish-instance = ${directory:varnish-data}/instance
cron-entries = ${rootdirectory:etc}/cron.d
crontabs = ${rootdirectory:etc}/crontabs
cronstamps = ${rootdirectory:etc}/cronstamps
logrotate-backup = ${basedirectory:backup}/logrotate
logrotate-entries = ${rootdirectory:etc}/logrotate.d
web-checker = ${rootdirectory:srv}/web-checker
[rootdirectory]
recipe = slapos.cookbook:mkdirectory
etc = ${buildout:directory}/etc
var = ${buildout:directory}/var
srv = ${buildout:directory}/srv
bin = ${buildout:directory}/bin
{% endif %}
This diff is collapsed.
......@@ -56,113 +56,27 @@ extra-context =
section parameter_dict dynamic-template-cloudooo-parameters
# Must match the key id in [switch-softwaretype] which uses this section.
raw software_type cloudooo
[dynamic-template-varnish-parameters]
dash = {{ dash_location }}
dcron = {{ dcron_location }}
gzip = {{ gzip_location }}
logrotate = {{ logrotate_location }}
stunnel = {{ stunnel_location }}
varnish = {{ varnish_location }}
wget = {{ wget_location }}
buildout-bin-directory = {{ buildout_bin_directory }}
[dynamic-template-varnish]
< = jinja2-template-base
template = {{ template_varnish }}
filename = instance-varnish.cfg
extra-context =
section parameter_dict dynamic-template-varnish-parameters
# Must match the key id in [switch-softwaretype] which uses this section.
raw software_type varnish
[dynamic-template-zope-parameters]
apache = {{ apache_location }}
aspell = {{ aspell_location }}
bin-directory = {{ bin_directory }}
coreutils = {{ coreutils_location }}
dcron = {{ dcron_location }}
dmtx-utils = {{ dmtx_utils_location }}
erp5 = {{ erp5_location }}
git = {{ git_location }}
graphviz = {{ graphviz_location }}
grep = {{ grep_location }}
gzip = {{ gzip_location }}
imagemagick = {{ imagemagick_location }}
librsvg = {{ librsvg_location }}
logrotate = {{ logrotate_location }}
mariadb = {{ mariadb_location }}
openssl = {{ openssl_location }}
poppler = {{ poppler_location }}
sed = {{ sed_location }}
tesseract = {{ tesseract_location }}
w3m = {{ w3m_location }}
jsl = {{ jsl_location }}
[dynamic-template-zope]
< = jinja2-template-base
template = {{ template_zope }}
filename = instance-zope.cfg
extensions = jinja2.ext.do
# XXX: duplicates above section, so less is modified in template in this
# commit. Should be replaced by a single "section" line.
extra-context =
key apache_location dynamic-template-zope-parameters:apache
key aspell_location dynamic-template-zope-parameters:aspell
key bin_directory dynamic-template-zope-parameters:bin-directory
key coreutils_location dynamic-template-zope-parameters:coreutils
key dcron_location dynamic-template-zope-parameters:dcron
key dmtx_utils_location dynamic-template-zope-parameters:dmtx-utils
key erp5_location dynamic-template-zope-parameters:erp5
key git_location dynamic-template-zope-parameters:git
key graphviz_location dynamic-template-zope-parameters:graphviz
key grep_location dynamic-template-zope-parameters:grep
key gzip_location dynamic-template-zope-parameters:gzip
key imagemagick_location dynamic-template-zope-parameters:imagemagick
key librsvg_location dynamic-template-zope-parameters:librsvg
key logrotate_location dynamic-template-zope-parameters:logrotate
key mariadb_location dynamic-template-zope-parameters:mariadb
key openssl_location dynamic-template-zope-parameters:openssl
key poppler_location dynamic-template-zope-parameters:poppler
key sed_location dynamic-template-zope-parameters:sed
key tesseract_location dynamic-template-zope-parameters:tesseract
key w3m_location dynamic-template-zope-parameters:w3m
key jsl_location dynamic-template-zope-parameters:jsl
[template-erp5-single-parameters]
bin-directory = {{ bin_directory }}
openssl = {{ openssl_location }}
local_bt5_repository = {{ local_bt5_repository }}
dash = {{ dash_location }}
curl = {{ curl_location }}
[template-erp5-single]
< = jinja2-template-base
template = {{ template_erp5_single }}
filename = instance-erp5-single.cfg
# XXX: duplicates above section, so less is modified in template in this
# commit. Should be replaced by a "section" line (preserving template_zope
# definition).
extra-context =
key bin_directory template-erp5-single-parameters:bin-directory
key openssl_location template-erp5-single-parameters:openssl
key curl_location template-erp5-single-parameters:curl
key dash_location template-erp5-single-parameters:dash
key template_zope dynamic-template-zope:rendered
key local_bt5_repository template-erp5-single-parameters:local_bt5_repository
[dynamic-template-cluster-erp5-parameters]
[dynamic-template-erp5-parameters]
local-bt5-repository = {{ local_bt5_repository }}
[dynamic-template-cluster-erp5]
[dynamic-template-erp5]
< = jinja2-template-base
template = {{ template_erp5_cluster }}
filename = instance-cluster-erp5.cfg
template = {{ template_erp5 }}
filename = instance-erp5.cfg
extensions = jinja2.ext.do
extra-context =
key local_bt5_repository dynamic-template-cluster-erp5-parameters:local-bt5-repository
key local_bt5_repository dynamic-template-erp5-parameters:local-bt5-repository
# Must match the key id in [switch-softwaretype] which uses this section.
raw software_type cluster
key software_type :software-type
software-type = default
[dynamic-template-erp5-cluster]
< = dynamic-template-erp5
software-type = cluster
[dynamic-template-erp5-RootSoftwareInstance]
< = dynamic-template-erp5
software-type = RootSoftwareInstance
[dynamic-template-balancer-parameters]
apache = {{ apache_location }}
......@@ -210,7 +124,7 @@ extra-context =
# Must match the key id in [switch-softwaretype] which uses this section.
raw software_type zodb-zeo
[dynamic-template-cluster-zope-parameters]
[dynamic-template-zope-parameters]
zope-conf-template = {{ template_zope_conf }}
instance-logrotate-cfg = {{ template_logrotate_base }}
git = {{ git_location }}
......@@ -229,16 +143,21 @@ openssl = {{ openssl_location }}
dash = {{ dash_location }}
jsl = {{ jsl_location }}
[dynamic-template-cluster-zope]
[dynamic-template-zope]
< = jinja2-template-base
template = {{ template_cluster_zope }}
filename = instance-cluster-zope.cfg
template = {{ template_zope }}
filename = instance-zope.cfg
extensions = jinja2.ext.do
extra-context =
key buildout_directory buildout:directory
section parameter_dict dynamic-template-cluster-zope-parameters
section parameter_dict dynamic-template-zope-parameters
# Must match the key id in [switch-softwaretype] which uses this section.
raw software_type cluster-zope
key software_type :software-type
software-type = zope
[dynamic-template-cluster-zope]
< = dynamic-template-zope
software-type = cluster-zope
[dynamic-template-kumofs-parameters]
dash-location = {{ dash_location }}
......@@ -283,17 +202,20 @@ extra-context =
[switch-softwaretype]
recipe = slapos.cookbook:softwaretype
default = ${template-erp5-single:rendered}
cluster = ${dynamic-template-cluster-erp5:rendered}
default = ${dynamic-template-erp5:rendered}
# BBB
cluster = ${dynamic-template-erp5-cluster:rendered}
cluster-zope = ${dynamic-template-cluster-zope:rendered}
# Common misspelling for "default".
RootSoftwareInstance = ${dynamic-template-erp5-RootSoftwareInstance:rendered}
kumofs = ${dynamic-template-kumofs:rendered}
cloudooo = ${dynamic-template-cloudooo:rendered}
zope = ${dynamic-template-zope:rendered}
mariadb = ${dynamic-template-mariadb:rendered}
varnish = ${dynamic-template-varnish:rendered}
balancer = ${dynamic-template-balancer:rendered}
zodb-neo = ${dynamic-template-neo:rendered}
zodb-zeo = ${dynamic-template-zeo:rendered}
cluster-zope = ${dynamic-template-cluster-zope:rendered}
zope = ${dynamic-template-zope:rendered}
[slap-connection]
# part to migrate to new - separated words
......
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