On Wed, 13 Mar 2019 at 07:11, <[email protected]> wrote:
>
> Ansible verison: 2.7.8
>
> I define role B as Role A dependencies in meta/main.yml like this:
> ```
> dependencies:
>   - { role: B, src: 'git+https://github.xxx/xxx/B.git', version: '1.0' }
>
> ```
>
> When I run playbook with Role A, I suppose ansible would download Role B 
> automatically. But not. Why?
> Shall I run ansible-galaxy install -r requirements.yml firstly?

Yes.

When a role is installed, any dependencies are automatically installed
as well (from 
https://galaxy.ansible.com/docs/using/installing.html#dependencies).
Running playbooks (i.e. deploying infrastructure) does not magically
pull in remote content.

So with ansible-galaxy you make sure all the roles etc are in place.
And then you playbooks can use them.


Dick

-- 
Dick Visser
Trust & Identity Service Operations Manager
GÉANT

-- 
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/CAL8fbwPyrbNQvGNc6AVU4Wz_U_xZpS2ZVk-_WSgW3%3DUWkv30pA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to