Advertisement
Guest User

Untitled

a guest
Jan 8th, 2016
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.74 KB | None | 0 0
  1. - hosts: test
  2. roles:
  3. - role: base
  4.  
  5. - name: base
  6. src: ssh://git@10.0.0.1/ansible/role-base.git
  7. scm: git
  8.  
  9. galaxy-info:
  10. author: Me
  11. description: Test Ansible role dependencies
  12. min_ansible_version: 1.9
  13. platforms: Ubuntu
  14. dependencies:
  15. - name: dep
  16. src: ssh://git@10.0.0.1/ansible/role-dep.git
  17. scm: git
  18.  
  19. $ ansible-galaxy -r requirements.yml
  20. - executing: git clone ssh://git@10.0.0.1/ansible/role-base.git base
  21. - executing: git archive --prefix=base/ --output=/tmp/tmp4YKG7a.tar
  22. - extracting base to ansible-roles/base
  23. - base was installed successfully
  24. - adding dependency: dep
  25. - executing: git clone ssh://git@10.0.0.1/ansible/role-dep.git dep
  26. - executing: git archive --prefix=dep/ --output=/tmp/tmpT2YiW4.tar
  27. - extracting base to ansible-roles/dep
  28. - dep was installed successfully
  29.  
  30. $ ansible-playbook play.yml
  31. ERROR: expected a role name in dictionary: {'scm': 'git', 'src': 'ssh://git@10.0.0.1/ansible/role-dep.git', 'name': 'dep'}
  32.  
  33. dependencies:
  34. - role: "git+ssh://git@10.0.0.1/ansible/role-dep.git,,dep"
  35.  
  36. $ ansible-galaxy -r requirements.yml
  37. - executing: git clone ssh://git@10.0.0.1/ansible/role-base.git base
  38. - executing: git archive --prefix=base/ --output=/tmp/tmpTcvpDu.tar
  39. - extracting base to ansible-roles/base
  40. - base was installed successfully
  41. - adding dependency: dep
  42. - executing: git clone ssh://git@10.0.0.1/ansible/role-dep.git dep
  43. - executing: git archive --prefix=dep/ --output=/tmp/tmpd726OV.tar
  44. - extracting base to ansible-roles/dep
  45. - dep was installed successfully
  46.  
  47. $ ansible-playbook play.yml
  48. ERROR: cannot find role in <pwd>/roles/git+ssh://git@10.0.0.1/ansible/role-dep.git,,dep or <pwd>/git+ssh://git@10.0.0.1/ansible/role-dep.git,,dep or <pwd>/ansible-roles/git+ssh://git@10.0.0.1/ansible/role-dep.git,,dep
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement