Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ovirt install: missing vsphere var?? #8

Open
vap0rtranz opened this issue Jun 25, 2020 · 2 comments
Open

ovirt install: missing vsphere var?? #8

vap0rtranz opened this issue Jun 25, 2020 · 2 comments

Comments

@vap0rtranz
Copy link

When running the oVirt installer, the playbook returns an error and evidently expects a vsphere variable:

[justin@ales-helpernode openshift-auto-upi]$ ansible-playbook openshift_ovirt.yml

PLAY [helper] ********************************************************************************************************************************************************************************
...

TASK [openshift_common : Copy install-config.yaml to the /home/justin/openshift-auto-upi-workspace/ocp4410/conf directory] *******************************************************************
fatal: [helper]: FAILED! => {"changed": false, "msg": "AnsibleUndefinedVariable: 'vsphere' is undefined"}

I checked the files that I'd edited for ovirt:

[justin@ales-helpernode openshift-auto-upi]$ ls -lrt inventory/group_vars/all/infra/
total 68
-rw-rw-r--. 1 justin justin 1642 Jun 25 15:59 helper.yml
-rw-rw-r--. 1 justin justin  123 Jun 25 15:59 dns_server.yml.sample
-rw-rw-r--. 1 justin justin  130 Jun 25 15:59 dnsmasq.yml.sample
-rw-rw-r--. 1 justin justin   40 Jun 25 15:59 dns_client.yml.sample
-rw-rw-r--. 1 justin justin  267 Jun 25 15:59 dhcp_server.yml.sample
-rw-rw-r--. 1 justin justin   41 Jun 25 15:59 check_dns.yml.sample
-rw-rw-r--. 1 justin justin  476 Jun 25 15:59 vsphere.yml.sample
-rw-rw-r--. 1 justin justin  424 Jun 25 15:59 ovirt.yml.sample
-rw-rw-r--. 1 justin justin 1790 Jun 25 15:59 mirror_registry.yml.sample
-rw-rw-r--. 1 justin justin  166 Jun 25 15:59 libvirt.yml.sample
-rw-rw-r--. 1 justin justin 4558 Jun 25 16:09 mirror_registry.yml
-rw-rw-r--. 1 justin justin  130 Jun 25 16:43 dnsmasq.yml
-rw-rw-r--. 1 justin justin  266 Jun 25 16:44 dhcp_server.yml
-rw-rw-r--. 1 justin justin  126 Jun 25 16:46 dns_server.yml
-rw-rw-r--. 1 justin justin   41 Jun 25 16:48 dns_client.yml
-rw-rw-r--. 1 justin justin  458 Jun 25 16:54 ovirt.yml

$ ls -lrt files/common/
total 8
-rw-rw-r--. 1 justin justin 2435 Jun 25 15:59 install-config.yaml.sample
-rw-rw-r--. 1 justin justin 2434 Jun 25 16:56 install-config.yaml

But the only vsphere enty in any of the files that I'd edited is the one in the install-config.yaml that's commented out:

[justin@ales-helpernode openshift-auto-upi]$ grep vsphere inventory/group_vars/all/infra/*.yml
[justin@ales-helpernode openshift-auto-upi]$ grep vsphere files/common/*.yaml
#  vsphere:
#    vcenter: '{{ vsphere.vcenter_hostname }}'
#    username: '{{ vsphere.vcenter_username  }}'
#    password: '{{ vsphere.vcenter_password  }}'
#    datacenter: '{{ vsphere.datacenter_name }}'
#    defaultDatastore: '{{ vsphere.datastore_name }}'

Is there something I missed setting up in the inventory files?

@noseka1
Copy link
Owner

noseka1 commented Jun 25, 2020

@vap0rtranz Thanks for reporting this. I think I know where the problem is. The vsphere related lines in the install-config.yaml look like they are commented out but actually they are not. Ansible Jinja templating is still trying to replace the tokens '{{ vsphere.xxx }}' and failing as there is no vsphere variable defined.

Please, remove the vsphere lines in the install-config.yaml. That should make it work.

@vap0rtranz
Copy link
Author

@noseka1 that worked. ty!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants