Configure DB addresses for each service
To enable partitioning of DB traffic by-service, each service needs to use a custom connection string. Defaulting the service address to a common galera_address makes things continue to work by default. While the galera_address could be overridden on a container or host basis this requires repeating that behavior across each infra node in the inventory. Providing service-specific connection address variables simplifies the management somewhat for large deployments and may reduce error rates. The service install playbooks now default the service-specific variables instead of galera_address to the internal lb vip from inventory to maintain the ease-of-use currently available. Any value for a service-specific variable set in user_variables.yml will override the value in the playbook's vars to provide selective customization as needed. Change-Id: I4c98bf906a0c1cb11ddd41277a855dce22ff646a Closes-Bug: 1462529
This commit is contained in:
committed by
Kevin Carter
parent
661e2a087f
commit
4310931756
@@ -24,4 +24,4 @@ This role will install the following:
|
|||||||
roles:
|
roles:
|
||||||
- { role: "os_nova", tags: [ "os-nova" ] }
|
- { role: "os_nova", tags: [ "os-nova" ] }
|
||||||
vars:
|
vars:
|
||||||
galera_address: "{{ internal_lb_vip_address }}"
|
nova_galera_address: "{{ internal_lb_vip_address }}"
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
mysql_db:
|
mysql_db:
|
||||||
login_user: "{{ galera_root_user }}"
|
login_user: "{{ galera_root_user }}"
|
||||||
login_password: "{{ galera_root_password }}"
|
login_password: "{{ galera_root_password }}"
|
||||||
login_host: "{{ galera_address }}"
|
login_host: "{{ nova_galera_address }}"
|
||||||
name: "{{ nova_galera_database }}"
|
name: "{{ nova_galera_database }}"
|
||||||
state: "present"
|
state: "present"
|
||||||
tags:
|
tags:
|
||||||
@@ -27,7 +27,7 @@
|
|||||||
mysql_user:
|
mysql_user:
|
||||||
login_user: "{{ galera_root_user }}"
|
login_user: "{{ galera_root_user }}"
|
||||||
login_password: "{{ galera_root_password }}"
|
login_password: "{{ galera_root_password }}"
|
||||||
login_host: "{{ galera_address }}"
|
login_host: "{{ nova_galera_address }}"
|
||||||
name: "{{ nova_galera_user }}"
|
name: "{{ nova_galera_user }}"
|
||||||
password: "{{ nova_container_mysql_password }}"
|
password: "{{ nova_container_mysql_password }}"
|
||||||
host: "{{ item }}"
|
host: "{{ item }}"
|
||||||
|
|||||||
@@ -176,7 +176,7 @@ check_revocations_for_cached = False
|
|||||||
|
|
||||||
{% if inventory_hostname not in groups['nova_compute'] %}
|
{% if inventory_hostname not in groups['nova_compute'] %}
|
||||||
[database]
|
[database]
|
||||||
connection = mysql://{{ nova_galera_user }}:{{ nova_container_mysql_password }}@{{ galera_address }}/{{ nova_galera_database }}?charset=utf8
|
connection = mysql://{{ nova_galera_user }}:{{ nova_container_mysql_password }}@{{ nova_galera_address }}/{{ nova_galera_database }}?charset=utf8
|
||||||
max_overflow = {{ nova_db_max_overflow }}
|
max_overflow = {{ nova_db_max_overflow }}
|
||||||
max_pool_size = {{ nova_db_max_pool_size }}
|
max_pool_size = {{ nova_db_max_pool_size }}
|
||||||
pool_timeout = {{ nova_db_pool_timeout }}
|
pool_timeout = {{ nova_db_pool_timeout }}
|
||||||
|
|||||||
Reference in New Issue
Block a user