diff --git a/roles/mgrote_minio_configure/tasks/bucket.yml b/roles/mgrote_minio_configure/tasks/bucket.yml index d14e3593..db5013ad 100644 --- a/roles/mgrote_minio_configure/tasks/bucket.yml +++ b/roles/mgrote_minio_configure/tasks/bucket.yml @@ -8,3 +8,4 @@ url: "{{ minio_url }}" state: present loop: "{{ minio_buckets }}" + # state mit default diff --git a/roles/mgrote_minio_configure/tasks/main.yml b/roles/mgrote_minio_configure/tasks/main.yml index 88f19066..eabcc0b3 100644 --- a/roles/mgrote_minio_configure/tasks/main.yml +++ b/roles/mgrote_minio_configure/tasks/main.yml @@ -1,4 +1,7 @@ --- +# auf Zielhost benötigt: pip3 install minio +# auf ansible-controller: https://galaxy.ansible.com/ui/repo/published/dubzland/minio/content/module/minio_alias/ + - name: include mcli tasks ansible.builtin.include_tasks: client.yml @@ -22,7 +25,7 @@ - name: include bucket tasks ansible.builtin.include_tasks: bucket.yml -- name: Add a Minio user +- name: Ensure users exist dubzland.minio.minio_user: access_key: "{{ item.name }}" secret_key: "{{ item.secret }}" @@ -34,16 +37,13 @@ state: "{{ item.state | default('present') }}" loop: "{{ minio_users }}" -- name: get all access keys (is set to true) +- name: "get all access keys (if set to true)" ansible.builtin.command: "{{ minio_client_bin }} --dp admin accesskey list {{ minio_root_alias }} --all" when: minio_print_keys register: all_keys changed_when: false -- name: geprintt all access keys (is set to true) +- name: "print all access keys (if set to true)" ansible.builtin.debug: msg: "{{ all_keys.stdout_lines }}" when: minio_print_keys - - -# https://galaxy.ansible.com/ui/repo/published/dubzland/minio/content/module/minio_alias/ + pip3 install minio