modified to setup contraints on single bindin space charms.
[joid.git] / ci / config_tpl / juju2 / bundle_tpl / mysql.yaml
1     mysql:
2       charm: "./{{ ubuntu.release }}/percona-cluster"
3       num_units: {{ unit_qty() }}
4 {% if os.service.bindings %}
5       bindings:
6         "": *oam-space
7         cluster: *internal-space
8         shared-db: *internal-space
9 {% endif %}
10       options:
11         innodb-buffer-pool-size: 1G
12         max-connections: 4000
13         #performance-schema: true
14         #source: "deb http://repo.percona.com/apt xenial main"
15         #key: "8507EFA5"
16         root-password: {{ get_password('mysql_root') }}
17         sst-password: {{ get_password('mysql_sst') }}
18         sst-method: rsync
19         wait-timeout: 180
20 {% if os.network.ipv6 %}
21         prefer-ipv6: {{ os.network.ipv6 }}
22 {% endif %}
23 {% if os.ha.mode == 'ha' %}
24         vip: {{ opnfv.vip.mysql }}
25 {% endif %}
26         min-cluster-size: {{ unit_qty() }}
27       to:
28 {% for unit_id in to_select() %}
29         - "lxd:nodes/{{ unit_id }}"
30 {% endfor %}