Hi

Frankly I'm not sure if this is a good solution (or if it even works, 
though I don't see why not). So my suggestion would be to have your local 
Ansible stuff (playbook, roles, etc.) install Ansible on Host A and push 
the playbooks etc. that you need to configure Host B onto Host A. In that 
way your Host A is to Host B what your local Computer is to Host A. 
Then at the end of deploying all that Stuff for Host B onto Host A you 
simply execute a shell command 
(https://docs.ansible.com/ansible/latest/modules/shell_module.html) on Host 
A where you execute ansible-playbook with the playbook(s) you wrote for 
Host B.

Hope that helps, regards,
Cyril



On Tuesday, 22 January 2019 17:16:04 UTC+1, [email protected] wrote:
>
> Ansible master -ssh- hostA -ssh- hostB, ansible master can not access 
> HostB directly. 
> If I want to deploy services on hostB, can I configure hostA in a 
> playbook, and include another playbook with hostB? 
> E.g - hosts: HostA 
>          Tasks: 
>           - include: inner playbook.yml 
> inner playbook: 
>        - hosts: HostB 
>         Tasks: 
>          .... 
> Actually, the method of playbook does not work. I don’t want to use ssh 
> proxy though it works. Does anyone else can give me with some suggestion? 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/f830f924-098e-4593-a38e-d446daed444e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to