spaced
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
17 additions and
10 deletions
-
roles/kubernetes-apps/external_provisioner/local_volume_provisioner/tasks/basedirs.yml
-
roles/kubernetes-apps/external_provisioner/local_volume_provisioner/tasks/main.yml
|
|
@ -0,0 +1,12 @@ |
|
|
|
--- |
|
|
|
# include to workaround mitogen issue |
|
|
|
# https://github.com/dw/mitogen/issues/663 |
|
|
|
|
|
|
|
- name: "Local Volume Provisioner | Ensure base dir {{ delegate_host_base_dir.1 }} is created on {{ delegate_host_base_dir.0 }}" |
|
|
|
file: |
|
|
|
path: "{{ local_volume_provisioner_storage_classes[delegate_host_base_dir.1].host_dir }}" |
|
|
|
state: directory |
|
|
|
owner: root |
|
|
|
group: root |
|
|
|
mode: "{{ local_volume_provisioner_directory_mode }}" |
|
|
|
delegate_to: "{{ delegate_host_base_dir.0 }}" |
|
|
@ -1,15 +1,10 @@ |
|
|
|
--- |
|
|
|
|
|
|
|
- name: Local Volume Provisioner | Ensure base dir is created on all hosts |
|
|
|
file: |
|
|
|
path: "{{ local_volume_provisioner_storage_classes[item.1].host_dir }}" |
|
|
|
state: directory |
|
|
|
owner: root |
|
|
|
group: root |
|
|
|
mode: "{{ local_volume_provisioner_directory_mode }}" |
|
|
|
delegate_to: "{{ item[0] }}" |
|
|
|
with_nested: |
|
|
|
- "{{ groups['k8s-cluster'] }}" |
|
|
|
- "{{ local_volume_provisioner_storage_classes.keys() | list }}" |
|
|
|
include_tasks: basedirs.yml |
|
|
|
loop_control: |
|
|
|
loop_var: delegate_host_base_dir |
|
|
|
loop: "{{ groups['k8s-cluster'] | product(local_volume_provisioner_storage_classes.keys()) | list }}" |
|
|
|
|
|
|
|
- name: Local Volume Provisioner | Create addon dir |
|
|
|
file: |
|
|
|