[kolla-ansible] Inventory group vars

Radosław Piliszek radoslaw.piliszek at gmail.com
Sat Mar 27 09:01:40 UTC 2021

On Fri, Mar 26, 2021 at 6:43 PM Alexandros Soumplis
<soumplis at admin.grnet.gr> wrote:
> Hi all,

Hi Alexandros,

> I am trying to define a couple of variables in the inventory file for a
> specific group and I do something like the following in the inventory:
> (...)
> [compute]
> comp[1:5]
> [compute:vars]
> neutron_external_interface=bond0.100, bond0.101
> neutron_bridge_name=br-ex,br-ex2
> (...)
> This is a valid ansible setup, however with kolla-ansible these
> variables are totally ignored. Any suggestion ?

That's interesting. Kolla Ansible does not do any magic at this level
so it's basically up to Ansible.
Perhaps there is a slight quirk somewhere. Maybe you have compute:vars
more than once? And override yourself?
Group vars work for me. It's good practice to use them.

You might also be interested in [1] where it shows how to organise the
vars in yaml files per group.

[1] https://docs.ansible.com/ansible/latest/user_guide/intro_inventory.html#organizing-host-and-group-variables


More information about the openstack-discuss mailing list