Revert "Optimize kube resources creation (#4572)" (#4621)

This reverts commit f8fdc0cd93.
This commit is contained in:
Maxime Guyot
2019-04-23 19:37:23 +02:00
committed by Matthew Mosesohn
parent 64f48bf84c
commit 50751bb610
22 changed files with 118 additions and 31 deletions

View File

@@ -24,9 +24,16 @@
- name: Start of Calico kube controllers
kube:
name: "{{item.item.name}}"
namespace: "kube-system"
kubectl: "{{bin_dir}}/kubectl"
filename: "{{ calico_node_manifests.results | selectattr('skipped', 'undefined') | map(attribute='item') | map(attribute='file') | map('regex_replace', '^(.*)$', kube_config_dir+'/\\1') | list }}"
resource: "{{item.item.type}}"
filename: "{{kube_config_dir}}/{{item.item.file}}"
state: "latest"
with_items:
- "{{ calico_kube_manifests.results }}"
when:
- inventory_hostname == groups['kube-master'][0]
- not item is skipped
loop_control:
label: "{{ item.item.file }}"