From 8f5b4cdbe151b509fc1309e1bc4fc19b4bc5950c Mon Sep 17 00:00:00 2001 From: Samuli Silvius Date: Mon, 13 May 2019 10:05:46 +0300 Subject: Make ovn-central network interface configurable installer.sh script is configuring ovn-central address : to environment variable. Ip address is detected from the ovn-central host through ansible by grepping ifconfig output, but in this step detected network interface is hard-coded in the code to be "eth1". This commit makes network interface configurable in aio/vagrant deployment. Issue-ID: MULTICLOUD-621 Change-Id: Icbe22ffdcb45c5f16067ea609eec76fb70c0ea78 Signed-off-by: Samuli Silvius --- kud/hosting_providers/baremetal/aio.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'kud/hosting_providers/baremetal/aio.sh') diff --git a/kud/hosting_providers/baremetal/aio.sh b/kud/hosting_providers/baremetal/aio.sh index 416a1fef..c9903cd3 100755 --- a/kud/hosting_providers/baremetal/aio.sh +++ b/kud/hosting_providers/baremetal/aio.sh @@ -15,9 +15,13 @@ set -o pipefail aio_dir=$(cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd) cd ${aio_dir}/../vagrant +# For aio inventory by default get ovn central ip from local host default interface. +# This variable used only in this file, but env variable defined to enable user to override it prior calling aio.sh. +OVN_CENTRAL_IP_ADDRESS=${OVN_CENTRAL_IP_ADDRESS:-$(hostname -I | cut -d ' ' -f 1)} + cat < inventory/hosts.ini [all] -localhost +localhost ansible_ssh_host=${OVN_CENTRAL_IP_ADDRESS} ansible_ssh_port=22 [kube-master] localhost -- cgit 1.2.3-korg