rook_block_storage_name: "block-storage"
rook_block_storage_fs: "xfs"
+rook_filesystem: "{{ lookup('env', 'ROOK_FS') | default('false', true) }}"
rook_filesystem_name: "rookfs"
rook_filesystem_storageclass_name: "csi-cephfs"
with_items:
- pool.yaml.j2
- storageclass.yaml.j2
+ loop_control:
+ loop_var: config_file
+
+- name: Create rook file system
+ k8s:
+ state: present
+ definition: "{{ lookup('template', config_file) }}"
+ with_items:
- filesystem.yaml.j2
- filesystem-storageclass.yaml.j2
loop_control:
loop_var: config_file
+ when: rook_filesystem|bool
- name: Create rook external dashboard
k8s: