IBM / Ansible-OpenShift-Provisioning

Automate the deployment of Red Hat OpenShift Container Platform on IBM zSystems (s390x). Automated User-Provisoned Infrastructure (UPI) setup using Kernel-based Virtual Machine (KVM).
https://ibm.github.io/Ansible-OpenShift-Provisioning/
MIT License
20 stars 44 forks source link

Under some circumstances the execution of playbooks first after fresh clone of repo #329

Closed AmadeusPodvratnik closed 2 months ago

AmadeusPodvratnik commented 2 months ago

ansible-playbook playbooks/0_setup.yaml [WARNING]: Unable to parse /Users/pod/Documents/OCP/code/GitHub/Repositories/Ansible-OpenShift-Provisioning/inventories/default as an inventory source [WARNING]: No inventory was parsed, only implicit localhost is available [WARNING]: provided hosts list is empty, only localhost is available. Note that the implicit localhost does not match 'all'

PLAY [localhost] ****

TASK [Gathering Facts] ** ok: [localhost] ERROR! an undefined variable was found when attempting to template the vars_files item '{{ inventory_dir }}/group_vars/disconnected.yaml'

The error appears to be in '/Users/pod/Documents/OCP/code/GitHub/Repositories/Ansible-OpenShift-Provisioning/playbooks/0_setup.yaml': line 9, column 7, but may be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

vars_files:

Should be written as:

with_items:
  - "{{ foo }}"

MBP-von-Amadeus:Ansible-OpenShift-Provisioning pod$ ansible-playbook playbooks/0_setup.yaml --extra-var inventory_dir=inventory/default [WARNING]: Unable to parse /Users/pod/Documents/OCP/code/GitHub/Repositories/Ansible-OpenShift-Provisioning/inventories/default as an inventory source [WARNING]: No inventory was parsed, only implicit localhost is available [WARNING]: provided hosts list is empty, only localhost is available. Note that the implicit localhost does not match 'all'

PLAY [localhost] ****

TASK [Check disconnected variables if disconnected cluster will be installed.] ** fatal: [localhost]: FAILED! => {"msg": "The conditional check 'disconnected.enabled' failed. The error was: error while evaluating conditional (disconnected.enabled): 'disconnected' is undefined\n\nThe error appears to be in '/Users/pod/Documents/OCP/code/GitHub/Repositories/Ansible-OpenShift-Provisioning/playbooks/0_setup.yaml': line 15, column 7, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n pre_tasks:\n - name: Check disconnected variables if disconnected cluster will be installed.\n ^ here\n"}

PLAY RECAP ** localhost : ok=0 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0