instance-resilient.cfg.jinja2 1.67 KB
Newer Older
1 2
# vim: set ft=cfg:

3 4 5 6
{% import 'parts' as parts %}
{% import 'replicated' as replicated %}

[buildout]
7 8 9
eggs-directory = {{ eggs_directory }}
develop-eggs-directory = {{ develop_eggs_directory }}
offline = true
10

11 12
# += because we need to take up parts (like instance-custom, slapmonitor etc) from the profile we extended
parts +=
13
  {{ parts.replicate("apache", "3") }}
14
  publish-connection-information
15

16
{{ replicated.replicate("apache", "3", "apache-export", "apache-import") }}
17

18 19 20
# Bubble up the parameters
[request-apache]
return = url ssh-public-key ssh-url notification-id ip url backend_url
21 22 23 24 25 26 27
# XXX: hardcoded values
config-mariadb1-computer-guid = ${slap-parameter:mariadb1-computer-guid}
config-pbs-mariadb1-computer-guid = ${slap-parameter:pbs-mariadb1-computer-guid}
config-mariadb2-computer-guid = ${slap-parameter:mariadb2-computer-guid}
config-pbs-mariadb2-computer-guid = ${slap-parameter:pbs-mariadb2-computer-guid}
config-mariadb3-computer-guid = ${slap-parameter:mariadb3-computer-guid}
config-pbs-mariadb3-computer-guid = ${slap-parameter:pbs-mariadb3-computer-guid}
28
config-domain = ${slap-parameter:domain}
29

30
[publish-connection-information]
31 32 33
recipe = slapos.cookbook:publish
backend_url = ${request-apache:connection-backend_url}
url = ${request-apache:connection-url}
34

35 36 37 38 39 40 41 42 43 44
[slap-parameter]
# Default parameters for distributed deployment
# I.e state "backup1 of maria should go there, ..."
# XXX-Cedric: Hardcoded number of backups. Should be dynamically generated.
mariadb1-computer-guid =
pbs-mariadb1-computer-guid =
mariadb2-computer-guid =
pbs-mariadb2-computer-guid =
mariadb3-computer-guid =
pbs-mariadb3-computer-guid =
45 46
# XXX-Cedric: Hardcoded parameters. Should be dynamically generated.
domain =