Description of problem: Currently the hosted-engine role can be executed only from the host it will be installed on. We should have the option to execute the role remotely, from another machine. Version-Release number of selected component (if applicable): 1.0.0
Raising priority here, since this is an enabler for Ansible Tower (AWX)/ Satellite(Foreman)/ CloudForms (ManageIQ)
This is already available if you are using directly the role.
I've tried to remotely deploy HE using these components: ovirt-ansible-hosted-engine-setup-1.0.11-0.1.master.20190206102238.el7.noarch ovirt-ansible-repositories-1.1.4-2.el7ev.noarch ovirt-ansible-engine-setup-1.1.7-1.el7ev.noarch ansible-2.7.7-1.el7ae.noarch ovirt-hosted-engine-ha-2.3.1-1.el7ev.noarch ovirt-hosted-engine-setup-2.3.3-1.el7ev.noarch Linux 3.10.0-957.5.1.el7.x86_64 #1 SMP Wed Dec 19 10:46:58 EST 2018 x86_64 x86_64 x86_64 GNU/Linux Red Hat Enterprise Linux Server release 7.6 (Maipo) Tried deploy from remote server puma19 using the same components and this yml: hosted_engine_deploy_remotehost.yml--- - name: Deploy oVirt hosted engine hosts: alma03.qa.lab.tlv.redhat.com vars: he_bridge_if: enp5s0f0 he_fqdn: nsednev-he-1.qa.lab.tlv.redhat.com he_vm_mac_addr: 00:16:3e:7b:b8:53 he_domain_type: nfs he_storage_domain_addr: yellow-vdsb.qa.lab.tlv.redhat.com he_storage_domain_path: /Compute_NFS/nsednev_he_1/ roles: - role: ovirt.hosted_engine_setup he_appliance_password: somepassword he_admin_password: anotherpassword puma19 ~]# ansible-playbook -i alma03.qa.lab.tlv.redhat.com, /root/hosted_engine_deploy_remotehost.yml Deployment failed with: fatal: [alma03.qa.lab.tlv.redhat.com -> nsednev-he-1.qa.lab.tlv.redhat.com]: FAILED! => {"changed": false, "elapsed": 195, "msg": "timed out waiting for ping module test success: Failed to connect to the host via ssh: ssh: connect to host nsednev-he-1.qa.lab.tlv.redhat.com port 22: Connection timed out"} Moving back to assigned. Please see https://bugzilla.redhat.com/show_bug.cgi?id=1676542 for more details.
Please try it with something like: cat he_deployment.json { "he_bridge_if": "enp5s0f0", "he_fqdn": "nsednev-he-1.qa.lab.tlv.redhat.com", "he_vm_mac_addr": "00:16:3e:7b:b8:53", "he_domain_type": "nfs", "he_storage_domain_addr": "yellow-vdsb.qa.lab.tlv.redhat.com", "he_storage_domain_path": "/Compute_NFS/nsednev_he_1/", "he_mem_size_MB": "4096", "he_ansible_host_name": "alma03.qa.lab.tlv.redhat.com" } cat passwords.yml he_appliance_password: 123456 he_admin_password: 123456 cat hosted_engine_deploy.yml --- - name: Deploy oVirt hosted engine hosts: alma03.qa.lab.tlv.redhat.com roles: - role: ovirt.hosted_engine_setup ansible-vault encrypt passwords.yml ansible-playbook -i alma03.qa.lab.tlv.redhat.com, hosted_engine_deploy.yml --extra-vars='@he_deployment.json' --extra-vars='@passwords.yml' --ask-vault-pass
puma18 ~]# ansible-playbook -i alma03.qa.lab.tlv.redhat.com, /root/hosted_engine_deploy.yml Deployment was successful over nfs with the following contents of yml: --- - name: Deploy oVirt hosted engine hosts: alma03.qa.lab.tlv.redhat.com vars: he_bridge_if: enp5s0f0 he_fqdn: nsednev-he-1.qa.lab.tlv.redhat.com he_vm_mac_addr: 00:16:3e:7b:b8:53 he_domain_type: nfs he_storage_domain_addr: yellow-vdsb.qa.lab.tlv.redhat.com he_storage_domain_path: /Compute_NFS/nsednev_he_1/ he_mem_size_MB: 4096 he_ansible_host_name: alma03.qa.lab.tlv.redhat.com he_appliance_password: somepassword he_admin_password: someanotherpassword roles: - role: ovirt.hosted_engine_setup Tested on: ovirt-hosted-engine-setup-2.3.6-1.el7ev.noarch ovirt-hosted-engine-ha-2.3.1-1.el7ev.noarch rhvm-appliance-4.3-20190305.1.el7.x86_64 ansible-2.7.8-1.el7ae.noarch ovirt-ansible-hosted-engine-setup-1.0.12-1.el7ev.noarch Linux 3.10.0-957.10.1.el7.x86_64 #1 SMP Thu Feb 7 07:12:53 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux Red Hat Enterprise Linux Server release 7.6 (Maipo) Moving to verified.
I've opened a doc bug to cover this RFE https://bugzilla.redhat.com/show_bug.cgi?id=1636919#c5
This bugzilla is included in oVirt 4.3.2 release, published on March 19th 2019. Since the problem described in this bug report should be resolved in oVirt 4.3.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.