kolla-ansible/ansible/roles/vitrage/tasks/precheck.yml
chenxing 2d1a1b1df6 Add vitrage ansible role
Co-Authored-By: caoyuan <cao.yuan@99cloud.net>
Co-Authored-By: Eduardo Gonzalez <dabarren@gmail.com>

Depends-on I7ffb991adbd05275e331401cd73fc84362084ebd
Change-Id: I85afeb5dfce0bf6350a444000bdb885c6fe079c9
Partially-implements: blueprint vitrage-roles
2017-12-18 17:29:32 +08:00

17 lines
452 B
YAML

---
- name: Get container facts
kolla_container_facts:
name:
- vitrage_api
register: container_facts
- name: Checking free port for vitrage API
wait_for:
host: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
port: "{{ vitrage_api_port }}"
connect_timeout: 1
state: stopped
when:
- container_facts['vitrage_api'] is not defined
- inventory_hostname in groups['vitrage-api']