Skip to content
This repository has been archived by the owner on Feb 29, 2024. It is now read-only.

Commit

Permalink
Fix available roles listing
Browse files Browse the repository at this point in the history
This change updates the expression which filters roles by role_tags.
In case when there are no role_tags defined in plan-environment.ymal
The expression should return all available roles

Closes-Bug: 1784605
Change-Id: I81051b0321c42c1b02974c5de310de88fb1a9d8b
  • Loading branch information
Jiri Tomasek committed Jul 31, 2018
1 parent 12ffda4 commit d83b4bf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion workbooks/plan_management.yaml
Expand Up @@ -1405,7 +1405,7 @@ workflows:
transform_output:
publish:
status: SUCCESS
available_roles: <% let(root => $, roles => yaml_parse($.available_yaml_roles.join("\n"))) -> $roles.where($root.role_tags.toSet().intersect($.get(tags, []).toSet()) or $root.role_tags = null) %>
available_roles: <% let(root => $, roles => yaml_parse($.available_yaml_roles.join("\n"))) -> ($root.role_tags = null and $roles or $roles.where($root.role_tags.toSet().intersect($.get(tags, []).toSet()))) %>
publish-on-error:
status: FAILED
message: <% task().result %>
Expand Down

0 comments on commit d83b4bf

Please sign in to comment.