Merge "add support for non-default database_port in kolla/ansible"
This commit is contained in:
commit
6f17a71d7f
@ -44,6 +44,7 @@ kolla_enable_sanity_swift: "{{ kolla_enable_sanity_checks }}"
|
||||
####################
|
||||
database_address: "{{ kolla_internal_fqdn }}"
|
||||
database_user: "root"
|
||||
database_port: "3306"
|
||||
|
||||
|
||||
####################
|
||||
@ -94,7 +95,7 @@ neutron_plugin_agent: "openvswitch"
|
||||
# The default ports used by each service.
|
||||
iscsi_port: "3260"
|
||||
|
||||
mariadb_port: "3306"
|
||||
mariadb_port: "{{ database_port }}"
|
||||
mariadb_wsrep_port: "4567"
|
||||
mariadb_ist_port: "4568"
|
||||
mariadb_sst_port: "4444"
|
||||
|
@ -24,7 +24,7 @@ cinder_backup_cache_mode: "{{ ceph_cinder_backup_cache_mode }}"
|
||||
####################
|
||||
cinder_database_name: "cinder"
|
||||
cinder_database_user: "cinder"
|
||||
cinder_database_address: "{{ kolla_internal_fqdn }}"
|
||||
cinder_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,6 +3,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ cinder_database_name }}'"
|
||||
@ -21,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ cinder_database_name }}'
|
||||
|
@ -23,7 +23,7 @@ glance_cache_mode: "{{ ceph_glance_cache_mode }}"
|
||||
####################
|
||||
glance_database_name: "glance"
|
||||
glance_database_user: "glance"
|
||||
glance_database_address: "{{ kolla_internal_fqdn }}"
|
||||
glance_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,8 +3,8 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ glance_database_name }}'"
|
||||
register: database
|
||||
@ -22,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ glance_database_name }}'
|
||||
|
@ -34,4 +34,4 @@
|
||||
- name: Waiting for virtual IP to appear
|
||||
wait_for:
|
||||
host: "{{ kolla_internal_vip_address }}"
|
||||
port: "{{ mariadb_port }}"
|
||||
port: "{{ database_port }}"
|
||||
|
@ -6,7 +6,7 @@ project_name: "heat"
|
||||
####################
|
||||
heat_database_name: "heat"
|
||||
heat_database_user: "heat"
|
||||
heat_database_address: "{{ kolla_internal_fqdn }}"
|
||||
heat_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,8 +3,8 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ heat_database_name }}'"
|
||||
register: database
|
||||
@ -22,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ heat_database_name }}'
|
||||
|
@ -6,7 +6,7 @@ project_name: "ironic"
|
||||
####################
|
||||
ironic_database_name: "ironic"
|
||||
ironic_database_user: "ironic"
|
||||
ironic_database_address: "{{ kolla_internal_fqdn }}"
|
||||
ironic_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,7 +3,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ ironic_database_name }}'"
|
||||
@ -22,7 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ ironic_database_name }}'
|
||||
|
@ -6,7 +6,7 @@ project_name: "keystone"
|
||||
####################
|
||||
keystone_database_name: "keystone"
|
||||
keystone_database_user: "keystone"
|
||||
keystone_database_address: "{{ kolla_internal_fqdn }}"
|
||||
keystone_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,7 +3,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ keystone_database_name }}'"
|
||||
@ -22,7 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ keystone_database_name }}'
|
||||
|
@ -6,7 +6,7 @@ project_name: "magnum"
|
||||
####################
|
||||
magnum_database_name: "magnum"
|
||||
magnum_database_user: "magnum"
|
||||
magnum_database_address: "{{ kolla_internal_fqdn }}"
|
||||
magnum_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,6 +3,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ magnum_database_name }}'"
|
||||
@ -21,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ magnum_database_name }}'
|
||||
|
@ -6,7 +6,7 @@ project_name: "manila"
|
||||
#####################
|
||||
manila_database_name: "manila"
|
||||
manila_database_user: "manila"
|
||||
manila_database_address: "{{ kolla_internal_fqdn }}"
|
||||
manila_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
#####################
|
||||
|
@ -3,6 +3,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ manila_database_name }}'"
|
||||
@ -21,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ manila_database_name }}'
|
||||
|
@ -1,6 +1,6 @@
|
||||
---
|
||||
- name: Waiting for MariaDB service to be ready through VIP
|
||||
command: "docker exec mariadb mysql -h {{ kolla_internal_fqdn }} -u haproxy -e 'show databases;'"
|
||||
command: "docker exec mariadb mysql -h {{ kolla_internal_fqdn }} -P {{ mariadb_port }} -u haproxy -e 'show databases;'"
|
||||
register: result
|
||||
until: result | success
|
||||
changed_when: False
|
||||
|
@ -6,7 +6,7 @@ project_name: "mistral"
|
||||
####################
|
||||
mistral_database_name: "mistral"
|
||||
mistral_database_user: "mistral"
|
||||
mistral_database_address: "{{ kolla_internal_fqdn }}"
|
||||
mistral_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,8 +3,8 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ mistral_database_name }}'"
|
||||
register: database
|
||||
@ -22,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ mistral_database_name }}'
|
||||
|
@ -6,7 +6,7 @@ project_name: "murano"
|
||||
####################
|
||||
murano_database_name: "murano"
|
||||
murano_database_user: "murano"
|
||||
murano_database_address: "{{ kolla_internal_fqdn }}"
|
||||
murano_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,8 +3,8 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_port='{{ mariadb_port }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ murano_database_name }}'"
|
||||
register: database
|
||||
@ -22,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ murano_database_name }}'
|
||||
|
@ -6,7 +6,7 @@ project_name: "neutron"
|
||||
####################
|
||||
neutron_database_name: "neutron"
|
||||
neutron_database_user: "neutron"
|
||||
neutron_database_address: "{{ kolla_internal_fqdn }}"
|
||||
neutron_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
|
||||
####################
|
||||
|
@ -3,6 +3,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ neutron_database_name }}'"
|
||||
@ -21,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ neutron_database_name }}'
|
||||
|
@ -19,11 +19,11 @@ nova_cache_mode: "{{ ceph_nova_cache_mode }}"
|
||||
####################
|
||||
nova_database_name: "nova"
|
||||
nova_database_user: "nova"
|
||||
nova_database_address: "{{ kolla_internal_fqdn }}"
|
||||
nova_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
nova_api_database_name: "nova_api"
|
||||
nova_api_database_user: "nova_api"
|
||||
nova_api_database_address: "{{ kolla_internal_fqdn }}"
|
||||
nova_api_database_address: "{{ kolla_internal_fqdn }}:{{ database_port }}"
|
||||
|
||||
####################
|
||||
# Docker
|
||||
|
@ -3,6 +3,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ nova_database_name }}'"
|
||||
@ -21,6 +22,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_db
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ nova_api_database_name }}'"
|
||||
@ -39,6 +41,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ nova_database_name }}'
|
||||
@ -57,6 +60,7 @@
|
||||
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
|
||||
-m mysql_user
|
||||
-a "login_host='{{ database_address }}'
|
||||
login_port='{{ database_port }}'
|
||||
login_user='{{ database_user }}'
|
||||
login_password='{{ database_password }}'
|
||||
name='{{ nova_api_database_name }}'
|
||||
|
@ -162,7 +162,7 @@
|
||||
- name: Checking free port for MariaDB
|
||||
wait_for:
|
||||
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
|
||||
port: "{{ mariadb_port }}"
|
||||
port: "{{ database_port }}"
|
||||
connect_timeout: 1
|
||||
state: stopped
|
||||
when: inventory_hostname in groups['mariadb']
|
||||
@ -170,7 +170,7 @@
|
||||
- name: Checking free port for MariaDB HAProxy
|
||||
wait_for:
|
||||
host: "{{ kolla_internal_vip_address }}"
|
||||
port: "{{ mariadb_port }}"
|
||||
port: "{{ database_port }}"
|
||||
connect_timeout: 1
|
||||
state: stopped
|
||||
when: inventory_hostname in groups['haproxy']
|
||||
|
Loading…
Reference in New Issue
Block a user