浏览代码

mux startup is broken without this fix

Rich Megginson 8 年之前
父节点
当前提交
6aa7ca988f
共有 2 个文件被更改,包括 2 次插入2 次删除
  1. 1 1
      roles/openshift_logging/tasks/start_cluster.yaml
  2. 1 1
      roles/openshift_logging/tasks/stop_cluster.yaml

+ 1 - 1
roles/openshift_logging/tasks/start_cluster.yaml

@@ -36,7 +36,7 @@
     name: "{{ object }}"
     namespace: "{{openshift_logging_namespace}}"
     replicas: "{{ openshift_logging_mux_replica_count | default (1) }}"
-  with_items: "{{ mux_dc.results.results[0]['items'] if 'results' in mux_dc else {} | map(attribute='metadata.name') | list }}"
+  with_items: "{{ mux_dc.results.results[0]['items'] | map(attribute='metadata.name') | list if 'results' in mux_dc else [] }}"
   loop_control:
     loop_var: object
   when:

+ 1 - 1
roles/openshift_logging/tasks/stop_cluster.yaml

@@ -36,7 +36,7 @@
     name: "{{ object }}"
     namespace: "{{openshift_logging_namespace}}"
     replicas: 0
-  with_items: "{{ mux_dc.results.results[0]['items'] if 'results' in mux_dc else {} | map(attribute='metadata.name') | list }}"
+  with_items: "{{ mux_dc.results.results[0]['items'] | map(attribute='metadata.name') | list if 'results' in mux_dc else [] }}"
   loop_control:
     loop_var: object
   when: openshift_logging_use_mux