main.yml 642 B

1234567891011121314151617181920212223
  1. ---
  2. - name: Create temp directory for doing work in
  3. command: mktemp -d /tmp/openshift-glusterfs-ansible-XXXXXX
  4. register: mktemp
  5. changed_when: False
  6. check_mode: no
  7. - include: glusterfs_config.yml
  8. when:
  9. - groups.glusterfs | default([]) | count > 0
  10. - include: glusterfs_registry.yml
  11. when: >
  12. groups.glusterfs_registry | default([]) | count > 0
  13. or (openshift_hosted_registry_storage_kind | default(none) == 'glusterfs')
  14. or (openshift_hosted_registry_storage_glusterfs_swap | default(False))
  15. - name: Delete temp directory
  16. file:
  17. name: "{{ mktemp.stdout }}"
  18. state: absent
  19. changed_when: False
  20. check_mode: no