---
- name: Ensure all node groups have bootstrap settings
  include_tasks: create_config.yml
  vars:
    l_openshift_node_group_name: "{{ node_group.name }}"
    l_openshift_node_group_edits:
    - key: servingInfo.certFile
      value: ""
    - key: servingInfo.keyFile
      value: ""
    - key: servingInfo.clientCA
      value: "client-ca.crt"
    - key: kubeletArguments.pod-manifest-path
      value:
      - /etc/origin/node/pods
    - key: kubeletArguments.bootstrap-kubeconfig
      value:
      - /etc/origin/node/bootstrap.kubeconfig
    - key: kubeletArguments.feature-gates
      value:
      - RotateKubeletClientCertificate=true,RotateKubeletServerCertificate=true
    - key: kubeletArguments.rotate-certificates
      value:
      - "true"
    - key: kubeletArguments.cert-dir
      value:
      - /etc/origin/node/certificates
    - key: masterKubeConfig
      value: node.kubeconfig
    l_openshift_node_group_labels: "{{ node_group.labels }}"
  with_items: "{{ openshift_node_groups }}"
  loop_control:
    loop_var: node_group
