kayobe/ansible/kolla-pip.yml
Michał Nasiadka 4a0eebf704 Stop using platform-python
Since python2 is not supported long time - there's
no need to use /usr/libexec/platform-python.
Also for supporting Debian/Ubuntu - we need to
change that to /usr/bin/python3.

Change-Id: I0d477325e0edd13d1aba211c13dc2e8b7a9b4c98
2020-12-14 14:48:05 +00:00

27 lines
800 B
YAML

---
- name: Configure local PyPi mirror for Kolla Ansible
hosts: seed:overcloud
gather_facts: false
tags:
- kolla-ansible
- kolla-pip
- pip
vars:
# kolla_overcloud_inventory_top_level_group_map looks like:
# kolla_overcloud_inventory_top_level_group_map:
# control:
# groups:
# - controllers
hosts_in_kolla_inventory: >-
{{ kolla_overcloud_inventory_top_level_group_map.values() |
map(attribute='groups') | flatten | unique | union(['seed']) | join(':') }}
ansible_python_interpreter: /usr/bin/python3
tasks:
- import_role:
name: pip
vars:
pip_applicable_users:
- "{{ kolla_ansible_user }}"
when:
- inventory_hostname in query('inventory_hostnames', hosts_in_kolla_inventory)