setup minio automation #229

Merged
mg merged 114 commits from minio_automation into master 2024-11-09 22:00:58 +01:00
2 changed files with 9 additions and 1 deletions
Showing only changes of commit 1b8beb0e9d - Show all commits

View file

@ -10,8 +10,12 @@ minio_config_dir: /etc/minio
minio_users:
- name: testuser5
secret: hallowelt
policies:
- testbucket1_rw
- name: testuser6
secret: hallowelt2
policies:
- testbucket3_ro
minio_buckets:
- name: testbucket1
@ -59,7 +63,7 @@ minio_policies:
}
]
}
- name: testbucketw_ro
- name: testbucket3_ro
policy: |
{
"Version": "2012-10-17",

View file

@ -17,3 +17,7 @@
- name: setup minio policies
ansible.builtin.command: "{{ minio_client_bin }} --dp admin policy create {{ item.name }} {{ minio_config_dir }}/{{ item.name }}"
loop: "{{ minio_policies }}"
- name: Assign MinIO policies to users
ansible.builtin.command: "{{ minio_client_bin }} --dp admin policy attach {{ item.1 }} --user {{ item.0.name }}"
loop: "{{ minio_users | subelements('policies') }}"