Generalize api_interface_address variable usage

Useful api_interface_address variable has been define here:
https://github.com/openstack/kolla-ansible/blob/master/ansible/group_vars/all.yml#L57
In order to simplify codebase we must use it as much as possible.

Change-Id: I18fec19bf69e05a22a4142a9cd1165eccd022455
This commit is contained in:
Bertrand Lallau 2017-04-18 09:10:44 +02:00
parent 97614a0960
commit afdd11b9a2
93 changed files with 133 additions and 133 deletions

View File

@ -7,7 +7,7 @@
- name: Checking free port for Aodh API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ aodh_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -9,7 +9,7 @@ transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}
[api]
port = {{ aodh_api_port }}
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
[database]
connection = mysql+pymysql://{{ aodh_database_user }}:{{ aodh_database_password }}@{{ aodh_database_address }}/{{ aodh_database_name }}

View File

@ -1,5 +1,5 @@
{% set python_path = '/usr/lib/python2.7/site-packages' if kolla_install_type == 'binary' else '/var/lib/kolla/venv/lib/python2.7/site-packages' %}
Listen {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ aodh_api_port }}
Listen {{ api_interface_address }}:{{ aodh_api_port }}
<VirtualHost *:{{ aodh_api_port }}>

View File

@ -7,7 +7,7 @@
- name: Checking free port for Barbican API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ barbican_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -1,5 +1,5 @@
[uwsgi]
socket = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ barbican_api_port }}
socket = {{ api_interface_address }}:{{ barbican_api_port }}
protocol = http
processes = {{ openstack_service_workers }}
lazy = true

View File

@ -3,7 +3,7 @@ debug = {{ barbican_logging_debug }}
log_dir = /var/log/kolla/barbican
bind_port = {{ barbican_api_port }}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
host_href = {{ public_protocol }}://{{ kolla_external_fqdn }}:{{ barbican_api_port }}
backlog = 4096
max_allowed_secret_in_bytes = 10000

View File

@ -7,7 +7,7 @@
- name: Checking free port for Ceilometer API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ ceilometer_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -21,7 +21,7 @@ meter_dispatchers = database
[api]
port = {{ ceilometer_api_port }}
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
[collector]

View File

@ -7,7 +7,7 @@
- name: Checking free port for RadosGW
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ rgw_port }}"
connect_timeout: 1
timeout: 1

View File

@ -34,7 +34,7 @@ mon cluster log file = /var/log/kolla/ceph/$cluster.log
[client.radosgw.gateway]
{% if orchestration_engine != 'KUBERNETES' %}
host = {{ hostvars[inventory_hostname]['ansible_' + storage_interface]['ipv4']['address'] }}
rgw frontends = civetweb port={{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ rgw_port }}
rgw frontends = civetweb port={{ api_interface_address }}:{{ rgw_port }}
{% endif %}
{% if enable_ceph_rgw_keystone | bool %}
rgw_keystone_url = {{ admin_protocol }}://{{ kolla_internal_fqdn }}:{{ keystone_admin_port }}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Cinder API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ cinder_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Cloudkitty API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ cloudkitty_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -47,7 +47,7 @@ auth_section = keystone_authtoken
{% endif %}
[api]
host_ip = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host_ip = {{ api_interface_address }}
port = {{ cloudkitty_api_port }}
[orchestrator]

View File

@ -2,7 +2,7 @@
@type syslog
port {{ fluentd_syslog_port }}
{% if orchestration_engine != 'KUBERNETES' %}
bind {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind {{ api_interface_address }}
{% else %}
bind 0.0.0.0
{% endif %}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Congress API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ congress_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -13,12 +13,12 @@ os_region_name = {{ openstack_region_name }}
# stderr and collected by Docker
use_stderr = False
my_ip = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
my_ip = {{ api_interface_address }}
api_paste_config = /etc/congress/api-paste.ini
{% if service_name == 'congress-api' %}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
bind_port = {{ congress_api_port }}
{% endif %}

View File

@ -9,7 +9,7 @@
- name: Checking free port for designate API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ designate_api_port }}"
connect_timeout: 1
timeout: 1
@ -31,7 +31,7 @@
- name: Checking free port for designate backend bind9 port
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ designate_bind_port }}"
connect_timeout: 1
timeout: 1
@ -43,7 +43,7 @@
- name: Checking free port for designate backend rndc port
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ designate_rndc_port }}"
connect_timeout: 1
timeout: 1

View File

@ -12,7 +12,7 @@ workers = {{ openstack_service_workers }}
[service:api]
api_base_uri = {{ internal_protocol }}://{{ kolla_internal_fqdn }}:{{ designate_api_port }}
api_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
api_host = {{ api_interface_address }}
api_port = {{ designate_api_port }}
enable_api_v1 = True
enabled_extensions_v1 = 'diagnostics, quotas, reports, sync, touch'

View File

@ -7,7 +7,7 @@
- name: Checking free port for Elasticsearch
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ elasticsearch_port }}"
connect_timeout: 1
timeout: 1

View File

@ -1,7 +1,7 @@
{% set num_nodes = groups['elasticsearch'] | length %}
{% set minimum_master_nodes = (num_nodes / 2 + 1) | round(0, 'floor') | int if num_nodes > 2 else 1 %}
{% set recover_after_nodes = (num_nodes * 2 / 3) | round(0, 'floor') | int if num_nodes > 1 else 1 %}
node.name: "{% if orchestration_engine == 'KUBERNETES' %}0.0.0.0{% else %}{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}{% endif %}"
node.name: "{{ api_interface_address }}"
network.host: {% if orchestration_engine == 'KUBERNETES' %}_eth0:ipv4_{% else %}"{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"{% endif %}
cluster.name: "{% if orchestration_engine == 'KUBERNETES' %}0.0.0.0{% else %}{{ elasticsearch_cluster_name }}{% endif %}"

View File

@ -9,10 +9,10 @@ etcd_services:
environment:
ETCD_DATA_DIR: "/var/lib/etcd"
ETCD_NAME: "{{ ansible_hostname }}"
ETCD_ADVERTISE_CLIENT_URLS: "{{ internal_protocol }}://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ etcd_client_port }}"
ETCD_LISTEN_CLIENT_URLS: "{{ internal_protocol }}://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ etcd_client_port }}"
ETCD_INITIAL_ADVERTISE_PEER_URLS: "{{ internal_protocol }}://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ etcd_peer_port }}"
ETCD_LISTEN_PEER_URLS: "{{ internal_protocol }}://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ etcd_peer_port }}"
ETCD_ADVERTISE_CLIENT_URLS: "{{ internal_protocol }}://{{ api_interface_address }}:{{ etcd_client_port }}"
ETCD_LISTEN_CLIENT_URLS: "{{ internal_protocol }}://{{ api_interface_address }}:{{ etcd_client_port }}"
ETCD_INITIAL_ADVERTISE_PEER_URLS: "{{ internal_protocol }}://{{ api_interface_address }}:{{ etcd_peer_port }}"
ETCD_LISTEN_PEER_URLS: "{{ internal_protocol }}://{{ api_interface_address }}:{{ etcd_peer_port }}"
ETCD_INITIAL_CLUSTER_TOKEN: "{{ etcd_cluster_token }}"
ETCD_INITIAL_CLUSTER: "{% for host in groups['etcd'] %}{{ hostvars[host]['ansible_hostname'] }}={{ internal_protocol }}://{{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}:{{ etcd_peer_port }}{% if not loop.last %},{% endif %}{% endfor %}"
ETCD_INITIAL_CLUSTER_STATE: "new"

View File

@ -7,7 +7,7 @@
- name: Checking free port for Etcd Peer
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ etcd_peer_port }}"
connect_timeout: 1
timeout: 1
@ -18,7 +18,7 @@
- name: Checking free port for Etcd Client
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ etcd_client_port }}"
connect_timeout: 1
timeout: 1

View File

@ -6,7 +6,7 @@
- name: Checking free port for Freezer API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ freezer_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -4,7 +4,7 @@ debug = {{ freezer_logging_debug }}
log_dir = /var/log/kolla/freezer
{% if service_name == 'freezer-api' %}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
bind_port = {{ freezer_api_port }}
{% endif %}

View File

@ -1,6 +1,6 @@
{% set freezer_log_dir = '/var/log/kolla/freezer' %}
{% set python_path = '/usr/lib/python2.7/site-packages' if kolla_install_type == 'binary' else '/var/lib/kolla/venv/lib/python2.7/site-packages' %}
Listen {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ freezer_api_port }}
Listen {{ api_interface_address }}:{{ freezer_api_port }}
<VirtualHost *:{{ freezer_api_port }}>
WSGIDaemonProcess freezer-api processes={{ openstack_service_workers }} threads=1 user=freezer display-name=%{GROUP}

View File

@ -6,7 +6,7 @@
- name: Checking free port for Glance API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ glance_api_port }}"
connect_timeout: 1
timeout: 1
@ -17,7 +17,7 @@
- name: Checking free port for Glance Registry
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ glance_registry_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Gnocchi API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ gnocchi_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -6,7 +6,7 @@ log_dir = /var/log/kolla/gnocchi
[api]
port = {{ gnocchi_api_port }}
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
middlewares = keystonemiddleware.auth_token.AuthProtocol
auth_mode = keystone

View File

@ -1,5 +1,5 @@
{% set python_path = '/usr/lib/python2.7/site-packages' if kolla_install_type == 'binary' else '/var/lib/kolla/venv/lib/python2.7/site-packages' %}
Listen {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ gnocchi_api_port }}
Listen {{ api_interface_address }}:{{ gnocchi_api_port }}
<VirtualHost *:{{ gnocchi_api_port }}>

View File

@ -7,7 +7,7 @@
- name: Checking free port for Grafana server
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ grafana_server_port }}"
connect_timeout: 1
timeout: 1

View File

@ -5,7 +5,7 @@ plugins = /var/lib/grafana/plugins
[server]
protocol = http
http_addr = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
http_addr = {{ api_interface_address }}
http_port = {{ grafana_server_port }}
router_logging = true

View File

@ -5,7 +5,7 @@ global
group haproxy
daemon
{% if orchestration_engine != 'KUBERNETES' %}
log {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ fluentd_syslog_port }} local1
log {{ api_interface_address }}:{{ fluentd_syslog_port }} local1
{% endif %}
maxconn 4000
stats socket /var/lib/kolla/haproxy/haproxy.sock
@ -30,7 +30,7 @@ defaults
timeout check 10s
listen stats
bind {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ haproxy_stats_port }}
bind {{ api_interface_address }}:{{ haproxy_stats_port }}
mode http
stats enable
stats uri /

View File

@ -8,7 +8,7 @@
- name: Checking free port for Heat API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ heat_api_port }}"
connect_timeout: 1
timeout: 1
@ -19,7 +19,7 @@
- name: Checking free port for Heat API CFN
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ heat_api_cfn_port }}"
connect_timeout: 1
timeout: 1

View File

@ -9,7 +9,7 @@
vars:
horizon: "{{ horizon_services['horizon'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ horizon_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Influxdb Admin
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ influxdb_admin_port }}"
connect_timeout: 1
timeout: 1
@ -18,7 +18,7 @@
- name: Checking free port for Influxdb Http
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ influxdb_http_port }}"
connect_timeout: 1
timeout: 1

View File

@ -8,7 +8,7 @@
- name: Checking free port for Ironic API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ ironic_api_port }}"
connect_timeout: 1
timeout: 1
@ -19,7 +19,7 @@
- name: Checking free port for Ironic Inspector
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ ironic_inspector_port }}"
connect_timeout: 1
timeout: 1

View File

@ -14,7 +14,7 @@ transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}
[api]
{% if orchestration_engine != 'KUBERNETES' %}
host_ip = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host_ip = {{ api_interface_address }}
{% else %}
host_ip = 0.0.0.0
{% endif %}

View File

@ -7,7 +7,7 @@
- name: Checking free port for iscsi
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ iscsi_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Karbor Admin
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ karbor_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -4,7 +4,7 @@ log_dir = /var/log/kolla/karbor
transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}:{{ rabbitmq_password }}@{% if orchestration_engine == 'KUBERNETES' %}rabbitmq{% else %}{{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}{% endif %}:{{ rabbitmq_port }}{% if not loop.last %},{% endif %}{% endfor %}
{% if service_name == 'karbor-api' %}
osapi_karbor_listen = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
osapi_karbor_listen = {{ api_interface_address }}
osapi_karbor_listen_port = {{ karbor_api_port }}
osapi_karbor_workers = {{ openstack_service_workers }}
{% endif %}

View File

@ -8,7 +8,7 @@
- name: Checking free port for Keystone Admin
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ keystone_admin_port }}"
connect_timeout: 1
timeout: 1
@ -19,7 +19,7 @@
- name: Checking free port for Keystone Public
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ keystone_public_port }}"
connect_timeout: 1
timeout: 1
@ -32,7 +32,7 @@
vars:
keystone_ssh: "{{ keystone_services['keystone-ssh'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ keystone_ssh_port }}"
connect_timeout: 1
timeout: 1

View File

@ -1,5 +1,5 @@
Port {{ keystone_ssh_port }}
ListenAddress {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
ListenAddress {{ api_interface_address }}
SyslogFacility AUTHPRIV
UsePAM yes

View File

@ -1,7 +1,7 @@
kibana.defaultAppId: "{{ kibana_default_app_id }}"
logging.dest: /var/log/kolla/kibana/kibana.log
server.port: {{ kibana_server_port }}
server.host: "{% if orchestration_engine == 'KUBERNETES' %}0.0.0.0{% else %}{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}{% endif %}"
server.host: "{{ api_interface_address }}"
elasticsearch.url: "{{ internal_protocol }}://{% if orchestration_engine == 'KUBERNETES' %}elasticsearch{% else %}{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}{% endif %}:{{ elasticsearch_port }}"
elasticsearch.requestTimeout: {{ kibana_elasticsearch_request_timeout }}
elasticsearch.shardTimeout: {{ kibana_elasticsearch_shard_timeout }}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Kuryr
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ kuryr_port }}"
connect_timeout: 1
timeout: 1

View File

@ -1,5 +1,5 @@
[DEFAULT]
kuryr_uri = http://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ kuryr_port }}
kuryr_uri = http://{{ api_interface_address }}:{{ kuryr_port }}
debug = {{ kuryr_logging_debug }}
[binding]

View File

@ -1 +1 @@
http://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ kuryr_port }}
http://{{ api_interface_address }}:{{ kuryr_port }}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Magnum API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ magnum_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -3,14 +3,14 @@ debug = {{ magnum_logging_debug }}
state_path = /var/lib/magnum
log_dir = /var/log/kolla/magnum
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}:{{ rabbitmq_password }}@{{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}:{{ rabbitmq_port }}{% if not loop.last %},{% endif %}{% endfor %}
{% if service_name == 'magnum-api' %}
[api]
port = {{ magnum_api_port }}
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
workers = {{ openstack_service_workers }}
{% endif %}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Manila API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ manila_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -4,9 +4,9 @@ debug = {{ manila_logging_debug }}
log_dir = /var/log/kolla/manila
use_forwarded_for = true
my_ip = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
my_ip = {{ api_interface_address }}
osapi_share_listen = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
osapi_share_listen = {{ api_interface_address }}
osapi_share_listen_port = {{ manila_api_port }}
osapi_share_workers = {{ openstack_service_workers }}

View File

@ -7,7 +7,7 @@
- name: Checking free port for MariaDB
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ database_port }}"
connect_timeout: 1
timeout: 1
@ -17,7 +17,7 @@
- name: Checking free port for MariaDB WSREP
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ mariadb_wsrep_port }}"
connect_timeout: 1
timeout: 1
@ -27,7 +27,7 @@
- name: Checking free port for MariaDB IST
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ mariadb_ist_port }}"
connect_timeout: 1
timeout: 1
@ -37,7 +37,7 @@
- name: Checking free port for MariaDB SST
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ mariadb_sst_port }}"
connect_timeout: 1
timeout: 1

View File

@ -3,7 +3,7 @@
kolla_toolbox:
module_name: mysql_user
module_args:
login_host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
login_host: "{{ api_interface_address }}"
login_port: "{{ mariadb_port }}"
login_user: "{{ database_user }}"
login_password: "{{ database_password }}"

View File

@ -20,7 +20,7 @@
# https://github.com/ansible/ansible-modules-core/issues/2788
- name: Waiting for MariaDB service to be ready
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ mariadb_port }}"
connect_timeout: 1
timeout: 60

View File

@ -7,7 +7,7 @@
- name: Checking free port for Memcached
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ memcached_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Mistral API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ mistral_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -11,7 +11,7 @@ transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}
{% if service_name == 'mistral-api' %}
[api]
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
port = {{ mistral_api_port }}
api_workers = {{ openstack_service_workers }}
{% endif %}

View File

@ -4,7 +4,7 @@
run_once: True
- name: Bootstraping the mongodb replication set
command: "docker exec -t mongodb mongo {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }} --quiet --eval '{{ lookup('file','/tmp/mongodb_bootstrap_replication_set.js') }}'"
command: "docker exec -t mongodb mongo {{ api_interface_address }} --quiet --eval '{{ lookup('file','/tmp/mongodb_bootstrap_replication_set.js') }}'"
register: bootstrap_mongodb_cluster
failed_when: "{{ (bootstrap_mongodb_cluster.stdout|from_json).ok != 1 }}"
delegate_to: "{{ groups['mongodb'][0] }}"

View File

@ -7,7 +7,7 @@
- name: Checking free port for Mongodb
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ mongodb_port }}"
connect_timeout: 1
timeout: 1
@ -18,7 +18,7 @@
- name: Checking free port for Mongodb Web
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ mongodb_web_port }}"
connect_timeout: 1
timeout: 1

View File

@ -13,10 +13,10 @@
- "mongodb:/var/lib/mongodb"
- name: Waiting for the mongodb startup
wait_for: host={{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }} port={{ mongodb_port }}
wait_for: host={{ api_interface_address }} port={{ mongodb_port }}
- name: Checking current replication status
command: "docker exec -t mongodb mongo {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }} --quiet --eval rs.status().ok"
command: "docker exec -t mongodb mongo {{ api_interface_address }} --quiet --eval rs.status().ok"
register: mongodb_replication_status
changed_when: false
delegate_to: "{{ groups['mongodb'][0] }}"

View File

@ -10,7 +10,7 @@ storage:
enabled: true
net:
bindIp: {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bindIp: {{ api_interface_address }}
port: {{ mongodb_port }}
replication:

View File

@ -7,7 +7,7 @@
- name: Checking free port for Murano API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ murano_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -4,7 +4,7 @@ debug = {{ murano_logging_debug }}
log_dir = /var/log/kolla/murano
{% if service_name == 'murano-api' %}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
bind_port = {{ murano_api_port }}
{% endif %}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Neutron Server
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ neutron_server_port }}"
connect_timeout: 1
timeout: 1

View File

@ -20,7 +20,7 @@
vars:
nova_api: "{{ nova_services['nova-api'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ nova_api_port }}"
connect_timeout: 1
timeout: 1
@ -34,7 +34,7 @@
vars:
nova_api: "{{ nova_services['nova-api'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ nova_metadata_port }}"
connect_timeout: 1
timeout: 1
@ -48,7 +48,7 @@
vars:
nova_novncproxy: "{{ nova_services['nova-novncproxy'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ nova_novncproxy_port }}"
connect_timeout: 1
timeout: 1
@ -62,7 +62,7 @@
vars:
nova_serialproxy: "{{ nova_services['nova-serialproxy'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ nova_serialproxy_port }}"
connect_timeout: 1
timeout: 1
@ -76,7 +76,7 @@
vars:
nova_spicehtml5proxy: "{{ nova_services['nova-spicehtml5proxy'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ nova_spicehtml5proxy_port }}"
connect_timeout: 1
timeout: 1
@ -90,7 +90,7 @@
vars:
nova_ssh: "{{ nova_services['nova-ssh'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ nova_ssh_port }}"
connect_timeout: 1
timeout: 1
@ -104,7 +104,7 @@
vars:
placement_api: "{{ nova_services['placement-api'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ placement_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -89,9 +89,9 @@ html5proxy_port = {{ nova_spicehtml5proxy_port }}
[serial_console]
enabled = true
base_url = ws://{{ kolla_external_fqdn }}:{{ nova_serialproxy_port }}/
serialproxy_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
serialproxy_host = {{ api_interface_address }}
serialproxy_port = {{ nova_serialproxy_port }}
proxyclient_address = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
proxyclient_address = {{ api_interface_address }}
{% endif %}
{% if service_name == "nova-compute-ironic" %}

View File

@ -8,7 +8,7 @@
- name: Checking free port for Octavia API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ octavia_api_port }}"
connect_timeout: 1
timeout: 1
@ -19,7 +19,7 @@
- name: Checking free port for Octavia Health Manager
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ octavia_health_manager_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@ api_handler = queue_producer
transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}:{{ rabbitmq_password }}@{{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}:{{ rabbitmq_port }}{% if not loop.last %},{% endif %}{% endfor %}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
bind_port = {{ octavia_api_port }}
[certificates]
@ -52,8 +52,8 @@ memcached_servers = {% for host in groups['memcached'] %}{{ hostvars[host]['ansi
[health_manager]
bind_port = {{ octavia_health_manager_port }}
bind_ip = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
controller_ip_port_list = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ octavia_health_manager_port }}
bind_ip = {{ api_interface_address }}
controller_ip_port_list = {{ api_interface_address }}:{{ octavia_health_manager_port }}
heartbeat_key =insecure
[controller_worker]

View File

@ -9,7 +9,7 @@
vars:
openvswitch_db: "{{ openvswitch_services['openvswitch-db-server'] }}"
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ ovsdb_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Panko API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ panko_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -1,5 +1,5 @@
{% set python_path = '/usr/lib/python2.7/site-packages' if kolla_install_type == 'binary' else '/var/lib/kolla/venv/lib/python2.7/site-packages' %}
Listen {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ panko_api_port }}
Listen {{ api_interface_address }}:{{ panko_api_port }}
<VirtualHost *:{{ panko_api_port }}>

View File

@ -13,4 +13,4 @@
- name: Checking the api_interface ip address configuration
fail: "msg='Please check the api_interface settings - interface {{ api_interface }} ip address problem'"
when: hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] is not defined
when: api_interface_address is not defined

View File

@ -7,7 +7,7 @@
- name: Checking free port for RabbitMQ
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ rabbitmq_port }}"
connect_timeout: 1
timeout: 1
@ -18,7 +18,7 @@
- name: Checking free port for RabbitMQ Management
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ rabbitmq_management_port }}"
connect_timeout: 1
timeout: 1
@ -29,7 +29,7 @@
- name: Checking free port for RabbitMQ Cluster
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ rabbitmq_cluster_port }}"
connect_timeout: 1
timeout: 1
@ -40,7 +40,7 @@
- name: Checking free port for RabbitMQ EPMD
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ rabbitmq_epmd_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Sahara API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ sahara_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -2,7 +2,7 @@
debug = {{ sahara_logging_debug }}
log_dir = /var/log/kolla/sahara
port = {{ sahara_api_port }}
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}:{{ rabbitmq_password }}@{{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}:{{ rabbitmq_port }}{% if not loop.last %},{% endif %}{% endfor %}
use_neutron = True

View File

@ -7,7 +7,7 @@
- name: Checking free port for Searchlight API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ searchlight_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -8,7 +8,7 @@ transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}
[api]
port = {{ searchlight_api_port }}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
public_endpoint = {{ public_protocol }}://{{ kolla_external_fqdn }}:{{ searchlight_api_port }}
workers = {{ openstack_service_workers }}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Senlin API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ senlin_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@
- name: Checking free port for Solum Application Deployment
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ solum_application_deployment_port }}"
connect_timeout: 1
timeout: 1
@ -18,7 +18,7 @@
- name: Checking free port for Solum Image Builder
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ solum_image_builder_port }}"
connect_timeout: 1
timeout: 1

View File

@ -3,7 +3,7 @@ debug = {{ solum_logging_debug }}
log_dir = /var/log/kolla/solum
{% if service_name == 'solum-api' %}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
bind_port = {{ solum_application_deployment_port }}
{% endif %}

View File

@ -54,7 +54,7 @@
- name: Checking free port for Swift Proxy Server
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ swift_proxy_server_port }}"
connect_timeout: 1
timeout: 1

View File

@ -3,7 +3,7 @@ bind_ip = {{ hostvars[inventory_hostname]['ansible_' + storage_interface]['ipv4'
bind_port = {{ swift_account_server_port }}
devices = {{ swift_devices_mount_point }}
mount_check = false
log_udp_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
log_udp_host = {{ api_interface_address }}
log_udp_port = {{ fluentd_syslog_port }}
log_name = {{ service_name }}
log_facility = LOG_LOCAL0

View File

@ -3,7 +3,7 @@ bind_ip = {{ hostvars[inventory_hostname]['ansible_' + storage_interface]['ipv4'
bind_port = {{ swift_container_server_port }}
devices = {{ swift_devices_mount_point }}
mount_check = false
log_udp_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
log_udp_host = {{ api_interface_address }}
log_udp_port = {{ fluentd_syslog_port }}
log_name = {{ service_name }}
log_facility = LOG_LOCAL0

View File

@ -4,7 +4,7 @@ bind_port = {{ swift_object_server_port }}
devices = {{ swift_devices_mount_point }}
mount_check = false
log_udp_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
log_udp_host = {{ api_interface_address }}
log_udp_port = {{ fluentd_syslog_port }}
log_name = {{ service_name }}
log_facility = LOG_LOCAL0

View File

@ -1,8 +1,8 @@
[DEFAULT]
bind_ip = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_ip = {{ api_interface_address }}
bind_port = {{ swift_proxy_server_port }}
log_udp_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
log_udp_host = {{ api_interface_address }}
log_udp_port = {{ fluentd_syslog_port }}
log_name = {{ service_name }}
log_facility = LOG_LOCAL0

View File

@ -1,6 +1,6 @@
uid = swift
gid = swift
address = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
address = {{ api_interface_address }}
{% if inventory_hostname in groups['swift-account-server'] %}
[account]

View File

@ -7,7 +7,7 @@
- name: Checking free port for Tacker Server
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ tacker_server_port }}"
connect_timeout: 1
timeout: 1

View File

@ -35,21 +35,21 @@
interfaces = []
{% if inventory_hostname in groups['haproxy'] and enable_haproxy | bool %}
[[inputs.haproxy]]
servers = ["{{ haproxy_proto }}://{{ haproxy_user }}:{{ haproxy_password }}@{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ haproxy_stats_port }}"]
servers = ["{{ haproxy_proto }}://{{ haproxy_user }}:{{ haproxy_password }}@{{ api_interface_address }}:{{ haproxy_stats_port }}"]
{% endif %}
{% if inventory_hostname in groups['memcached'] and enable_memcached | bool %}
[[inputs.memcached]]
servers = ["{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ memcached_port }}"]
servers = ["{{ api_interface_address }}:{{ memcached_port }}"]
{% endif %}
{% if inventory_hostname in groups['elasticsearch'] and enable_elasticsearch | bool %}
[[inputs.elasticsearch]]
servers = ["{{ elasticsearch_proto }}://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ elasticsearch_port }}"]
servers = ["{{ elasticsearch_proto }}://{{ api_interface_address }}:{{ elasticsearch_port }}"]
local = true
cluster_health = true
{% endif %}
{% if inventory_hostname in groups['rabbitmq'] and enable_rabbitmq | bool %}
[[inputs.rabbitmq]]
url = "{{ rabbitmq_proto }}://{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}:{{ rabbitmq_management_port }}"
url = "{{ rabbitmq_proto }}://{{ api_interface_address }}:{{ rabbitmq_management_port }}"
username = "{{ rabbitmq_user }}"
password = "{{ rabbitmq_password }}"
{% endif %}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Trove API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ trove_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -3,10 +3,10 @@ debug = {{ trove_logging_debug }}
log_dir = /var/log/kolla/trove
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
bind_port = {{ trove_api_port }}
bind_host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
bind_host = {{ api_interface_address }}
trove_api_workers = {{ openstack_service_workers }}
auth_strategy = keystone

View File

@ -7,7 +7,7 @@
- name: Checking free port for watcher API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ watcher_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -7,7 +7,7 @@ transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}
{% if service_name == 'watcher-api' %}
[api]
host = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
host = {{ api_interface_address }}
port = {{ watcher_api_port }}
{% endif %}

View File

@ -7,7 +7,7 @@
- name: Checking free port for Zun API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
host: "{{ api_interface_address }}"
port: "{{ zun_api_port }}"
connect_timeout: 1
timeout: 1

View File

@ -4,7 +4,7 @@ log_dir = /var/log/kolla/zun
transport_url = rabbit://{% for host in groups['rabbitmq'] %}{{ rabbitmq_user }}:{{ rabbitmq_password }}@{% if orchestration_engine == 'KUBERNETES' %}rabbitmq{% else %}{{ hostvars[host]['ansible_' + hostvars[host]['api_interface']]['ipv4']['address'] }}{% endif %}:{{ rabbitmq_port }}{% if not loop.last %},{% endif %}{% endfor %}
{% if service_name == 'zun-api' %}
osapi_zun_listen = {{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}
osapi_zun_listen = {{ api_interface_address }}
osapi_zun_listen_port = {{ zun_api_port }}
{% endif %}