diff options
Diffstat (limited to 'network/ports')
-rw-r--r-- | network/ports/net_ip_list_map.yaml | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/network/ports/net_ip_list_map.yaml b/network/ports/net_ip_list_map.yaml index 430158ac..07e2de4c 100644 --- a/network/ports/net_ip_list_map.yaml +++ b/network/ports/net_ip_list_map.yaml @@ -78,9 +78,15 @@ outputs: description: > Map of enabled services to a list of hostnames where they're running value: - map_merge: - repeat: - template: - SERVICE_node_names: {get_param: ServiceHostnameList} - for_each: - SERVICE: {get_param: EnabledServices} + yaql: + # If ServiceHostnameList is empty the role is deployed with zero nodes + # therefore we don't want to add any *_node_names to the map + expression: dict($.data.map.items().where(len($[1]) > 0)) + data: + map: + map_merge: + repeat: + template: + SERVICE_node_names: {get_param: ServiceHostnameList} + for_each: + SERVICE: {get_param: EnabledServices} |