---

- name: test
  hosts: localhost
  tasks:
    - add_host: name={{item}} groups=nodes
      with_items: "{{groups['compute']}}"
    - add_host: name={{item}} groups=nodes
      with_items: "{{groups['controller']}}"
    - add_host: name={{item}} groups=OSEv3
      with_items: "{{groups['overcloud']}}"

- name: Set vars for OSEv3
  hosts: OSEv3
  gather_Facts: no
  vars:
    ansible_become: true
    ansible_become_user: root
    ansible_ssh_user: heat-admin
    containerized: true
    openshift_use_dnsmasq: False
    openshift_deployment_type: origin
    openshift_release: v1.5
    openshift_image_tag: v1.5.0
    enable_excluders: False


- name: Set vars for masters group
  hosts: nodes
  gather_Facts: no
  vars:
    containerized: true
    openshift_schedulable: true
    openshift_excluder_on: false
    connect_to: "{{inventory_hostname}}"
    openshift_ip: "{{inventory_hostname}}"
    openshift_hostname: "{{inventory_hostname}}"
    openshift_public_ip: "{{inventory_hostname}}"
    openshift_public_hostname: "{{inventory_hostname}}"

- name: Set vars for nodes group
  hosts: nodes
  gather_Facts: no
  vars:
    containerized: true
    openshift_schedulable: true
    openshift_excluder_on: false
    connect_to: "{{inventory_hostname}}"
    openshift_ip: "{{inventory_hostname}}"
    openshift_hostname: "{{inventory_hostname}}"
    openshift_public_ip: "{{inventory_hostname}}"
    openshift_public_hostname: "{{inventory_hostname}}"

Add nodes to the in-memory inventory
Add nodes to the in-memory inventory
