aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2016-04-11 07:21:13 +0000
committerGerrit Code Review <review@openstack.org>2016-04-11 07:21:14 +0000
commit3da780044b3c379b31c80617ec313f54fbdc8616 (patch)
treeafd0164203f10bc3e2347d24f2d98f42ca9e375c
parentdf53d92db6464f5347d21972664caa69eb6d99a2 (diff)
parent1c0dcd8ba83aae488e855b371707349451a4e85f (diff)
downloadkolla-3da780044b3c379b31c80617ec313f54fbdc8616.tar.gz
kolla-3da780044b3c379b31c80617ec313f54fbdc8616.zip
Merge "Add prechecks to validate kolla_internal_vip_address and kolla_external_vip_address"
-rw-r--r--ansible/roles/prechecks/tasks/port_checks.yml16
1 files changed, 16 insertions, 0 deletions
diff --git a/ansible/roles/prechecks/tasks/port_checks.yml b/ansible/roles/prechecks/tasks/port_checks.yml
index 6c2ce7cc5..9f9c68853 100644
--- a/ansible/roles/prechecks/tasks/port_checks.yml
+++ b/ansible/roles/prechecks/tasks/port_checks.yml
@@ -446,3 +446,19 @@
connect_timeout: 1
state: stopped
when: inventory_hostname in groups['haproxy']
+
+- name: Checking if kolla_internal_vip_address and kolla_external_vip_address are not pingable from any node
+ command: ping -c 3 {{ item }}
+ register: ping_output
+ changed_when: false
+ with_items:
+ - "{{ kolla_internal_vip_address }}"
+ - "{{ kolla_external_vip_address }}"
+ failed_when: ping_output.rc != 1
+
+- name: Checking if kolla_internal_vip_address is in the same network as network_interface on all nodes
+ command: ip -4 -o addr show dev {{ network_interface }}
+ register: ip_addr_output
+ changed_when: false
+ failed_when: "'169.254.' not in kolla_internal_vip_address and \
+ 'False' in kolla_internal_vip_address | ipaddr(ip_addr_output.stdout.split()[3])"