This commit is contained in:
Michael Grote 2024-11-09 11:03:39 +01:00
parent 387711e2de
commit cc7eba6d9d

View file

@ -23,8 +23,9 @@
# > ./mc --dp admin accesskey list minio_root testuser7 # > ./mc --dp admin accesskey list minio_root testuser7
# User: testuser7 # User: testuser7
# 1. check if user has access keys # 1. check if user has access keys{wenn access}
# 2. when not create one, else skip # 2. when not create one, else skip
# whe exist, then display if param is set
- name: get access keys - name: get access keys
ansible.builtin.command: "{{ minio_client_bin }} --dp admin accesskey list {{ minio_root_alias }} {{ item.name }}" ansible.builtin.command: "{{ minio_client_bin }} --dp admin accesskey list {{ minio_root_alias }} {{ item.name }}"
@ -34,6 +35,7 @@
- name: debug - name: debug
ansible.builtin.debug: ansible.builtin.debug:
msg: "{{ keys }}" msg: "{{ keys }}"
when: '"Access Keys:" in keys'
- name: setup minio users - name: setup minio users
ansible.builtin.command: "{{ minio_client_bin }} --dp admin user add {{ minio_root_alias }} {{ item.name }} {{ item.secret }}" ansible.builtin.command: "{{ minio_client_bin }} --dp admin user add {{ minio_root_alias }} {{ item.name }} {{ item.secret }}"