mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-23 13:20:23 -07:00
Allow installation of roles from yaml roles file
Added docs Added more tests Improved how roles are returned from the parsers
This commit is contained in:
parent
46b59b02ed
commit
ada9074276
7 changed files with 71 additions and 28 deletions
|
@ -187,7 +187,7 @@ class Play(object):
|
|||
raise errors.AnsibleError("expected a role name in dictionary: %s" % orig_path)
|
||||
role_vars = orig_path
|
||||
else:
|
||||
(scm, role_src, role_version, role_name) = utils.role_spec_parse(orig_path)
|
||||
role_name = utils.role_spec_parse(orig_path)["name"]
|
||||
|
||||
role_path = None
|
||||
|
||||
|
@ -412,8 +412,7 @@ class Play(object):
|
|||
if isinstance(role, dict):
|
||||
role_name = role['role']
|
||||
else:
|
||||
role_name = role
|
||||
(scm, role_src, role_version, role_name) = utils.role_spec_parse(role_name)
|
||||
role_name = utils.role_spec_parse(role)["name"]
|
||||
|
||||
role_names.append(role_name)
|
||||
if os.path.isfile(task):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue