Bug 1539715
| Summary: | Make hosts variable optional (for example to be able to add additional storage domains to existing setup) | ||
|---|---|---|---|
| Product: | [oVirt] ovirt-ansible-collection | Reporter: | Petr Kubica <pkubica> |
| Component: | infra | Assignee: | Ondra Machacek <omachace> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Petr Kubica <pkubica> |
| Severity: | medium | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | unspecified | CC: | mperina |
| Target Milestone: | ovirt-4.2.2 | Flags: | rule-engine:
ovirt-4.2+
|
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | ovirt-ansible-infra-1.1.4 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2018-03-29 11:04:45 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | Infra | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
Verified in ovirt-ansible-infra-1.1.4-1.el7ev.noarch This bugzilla is included in oVirt 4.2.2 release, published on March 28th 2018. Since the problem described in this bug report should be resolved in oVirt 4.2.2 release, it has been closed with a resolution of CURRENT RELEASE. If the solution does not work for you, please open a new bug report. |
Description of problem: infra role expect variable hosts but in cluster are already added some hosts or user can setup only parts in which host isn't required - create empty clusters, add users... Version-Release number of selected component (if applicable): ovirt-ansible-infra-1.1.2-1.el7ev.noarch ansible-2.4.1.0-1.el7ae.noarch Expected results: variable hosts shouldn't be mandatory, if user wants to add a storage domain without a host in data center, it should fail with appropriate error message Additional info: fatal: [localhost]: FAILED! => { "failed": true, "msg": "The task includes an option with an undefined variable. The error was: 'hosts' is undefined\n\nThe error appears to have been in '/usr/share/ansible/roles/oVirt.infra/roles/oVirt.hosts/tasks/main.yml': line 2, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n---\n- name: Get hosts\n ^ here\n\nexception type: <class 'ansible.errors.AnsibleUndefinedVariable'>\nexception: 'hosts' is undefined" }