You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
619 B

  1. ---
  2. - name: Kubernetes Persistent Volumes | Copy Cinder CSI Storage Class template
  3. template:
  4. src: "cinder-csi-storage-class.yml.j2"
  5. dest: "{{ kube_config_dir }}/cinder-csi-storage-class.yml"
  6. register: manifests
  7. when:
  8. - inventory_hostname == groups['kube-master'][0]
  9. - name: Kubernetes Persistent Volumes | Add Cinder CSI Storage Class
  10. kube:
  11. name: cinder-csi
  12. kubectl: "{{ bin_dir }}/kubectl"
  13. resource: StorageClass
  14. filename: "{{ kube_config_dir }}/cinder-csi-storage-class.yml"
  15. state: "latest"
  16. when:
  17. - inventory_hostname == groups['kube-master'][0]
  18. - manifests.changed