Align collection_file naming

At the moment we're inconsistent in collection_file variable naming.
While we're passing `collection_file` to the play, inside it we use
`collections_file`.

Closes-Bug: #1975723
Change-Id: Ia2814d6dc6faa509e98f7486fed12600e192ec8b
This commit is contained in:
Dmitriy Rabotyagov 2022-05-26 17:02:45 +02:00
parent 0823e54748
commit d501eadd94
2 changed files with 3 additions and 2 deletions

View File

@ -54,6 +54,7 @@ export OSA_CLONE_DIR="$(pwd)"
# Set the variable to the role file to be the absolute path
ANSIBLE_ROLE_FILE="$(readlink -f "${ANSIBLE_ROLE_FILE}")"
ANSIBLE_COLLECTION_FILE="$(readlink -f "${ANSIBLE_COLLECTION_FILE}")"
OSA_INVENTORY_PATH="$(readlink -f inventory)"
OSA_ANSIBLE_PYTHON_INTERPRETER="auto"

View File

@ -97,8 +97,8 @@
state: absent
vars:
collections_file: "{{ playbook_dir }}/../ansible-collection-requirements.yml"
required_collections: "{{ lookup('file', collections_file) | from_yaml }}"
collection_file: "{{ playbook_dir }}/../ansible-collection-requirements.yml"
required_collections: "{{ lookup('file', collection_file) | from_yaml }}"
collection_path_default: '/etc/ansible/'
user_collections: "{{ lookup('file', user_collections_path, errors='ignore')|default([], true) | from_yaml }}"
user_collections_path: "{{ lookup('env', 'OSA_CONFIG_DIR') | default('/etc/openstack_deploy', true) ~ '/' ~ (user_collection_file|default('')) }}"