Compare commits
4 commits
3fbf71c800
...
17ba98d102
Author | SHA1 | Date | |
---|---|---|---|
17ba98d102 | |||
8d20e0495c | |||
afbc38c2af | |||
3652309f1f |
5 changed files with 31 additions and 18 deletions
|
@ -1,4 +1,17 @@
|
||||||
---
|
---
|
||||||
|
### mgrote_minio_configure
|
||||||
|
minio_url: https://s3.mgrote.net
|
||||||
|
minio_root_access_key: "{{ lookup('viczem.keepass.keepass', 'minio_root_access_key', 'password') }}"
|
||||||
|
minio_root_secret_key: "{{ lookup('viczem.keepass.keepass', 'minio_root_secret_key', 'password') }}"
|
||||||
|
minio_users:
|
||||||
|
- name: testuser
|
||||||
|
secret: "{{ lookup('viczem.keepass.keepass', 'minio_testuser_secret_key', 'password') }}"
|
||||||
|
state: present
|
||||||
|
policy: testbucket_rw
|
||||||
|
minio_buckets:
|
||||||
|
- name: testbucket
|
||||||
|
state: present
|
||||||
|
|
||||||
### mrlesmithjr.manage_lvm
|
### mrlesmithjr.manage_lvm
|
||||||
lvm_groups:
|
lvm_groups:
|
||||||
- vgname: vg_docker
|
- vgname: vg_docker
|
||||||
|
@ -19,6 +32,7 @@ pvresize_to_max: true
|
||||||
pip_package: python3-pip
|
pip_package: python3-pip
|
||||||
pip_install_packages:
|
pip_install_packages:
|
||||||
- name: docker # für munin-plugin docker_
|
- name: docker # für munin-plugin docker_
|
||||||
|
- name: minio # für ansible-minio_configure-Rolle
|
||||||
|
|
||||||
### mgrote.apt_manage_packages
|
### mgrote.apt_manage_packages
|
||||||
apt_packages_extra:
|
apt_packages_extra:
|
||||||
|
|
BIN
keepass_db.kdbx
BIN
keepass_db.kdbx
Binary file not shown.
|
@ -1,15 +1,19 @@
|
||||||
---
|
---
|
||||||
minio_root_access_key: pfiDnpEL3rL1CmIedZbD # händisch zu erstellen beium ersten minio aufsetzen
|
# Client
|
||||||
minio_root_secret_key: Bc2eyAiTxLok0RawYguQJUB0hC8HtvCA7RjYRAfV # händisch zu erstellen beium ersten minio aufsetzen
|
|
||||||
minio_root_alias: minio_ansible_root
|
|
||||||
minio_url: https://s3.mgrote.net
|
|
||||||
minio_config_dir: /etc/minio
|
|
||||||
minio_client_release: ""
|
minio_client_release: ""
|
||||||
minio_client_bin: /usr/local/bin/mc
|
minio_client_bin: /usr/local/bin/mc
|
||||||
minio_print_keys: true # zeige secret in playbook
|
|
||||||
|
|
||||||
# --dp ausschreiben
|
# Allgemeines
|
||||||
|
minio_config_dir: /etc/minio
|
||||||
|
minio_root_alias: minio_ansible_root
|
||||||
|
|
||||||
|
minio_url: https://s3.mgrote.net
|
||||||
|
|
||||||
|
# Secrets
|
||||||
|
minio_root_access_key: pfiDnXXXXXedZbD
|
||||||
|
minio_root_secret_key: Bc2exxxxxxxxxxxxxYRAfV
|
||||||
|
|
||||||
|
# User
|
||||||
minio_users:
|
minio_users:
|
||||||
- name: testuser5
|
- name: testuser5
|
||||||
secret: hallowelt
|
secret: hallowelt
|
||||||
|
@ -24,13 +28,10 @@ minio_users:
|
||||||
state: absent
|
state: absent
|
||||||
policy: testbucket3_ro
|
policy: testbucket3_ro
|
||||||
|
|
||||||
|
# Buckets
|
||||||
# Anzulegende Buckets, pro Bucket wird eine RW + RO Policy erstellt
|
# Anzulegende Buckets, pro Bucket wird eine RW + RO Policy erstellt
|
||||||
minio_buckets:
|
minio_buckets:
|
||||||
- name: testbucket1
|
- name: testbucket1
|
||||||
state: present
|
state: present
|
||||||
- name: testbucket3
|
- name: testbucket3
|
||||||
state: absent
|
state: absent
|
||||||
|
|
||||||
|
|
||||||
# auf docker10 aufraumen
|
|
||||||
# und irtantu
|
|
||||||
|
|
|
@ -13,9 +13,6 @@
|
||||||
secret_key: "{{ minio_root_secret_key }}"
|
secret_key: "{{ minio_root_secret_key }}"
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
# bug:delegate to geht nciht
|
|
||||||
# linter
|
|
||||||
|
|
||||||
- name: include policy tasks
|
- name: include policy tasks
|
||||||
ansible.builtin.include_tasks: policy.yml
|
ansible.builtin.include_tasks: policy.yml
|
||||||
|
|
||||||
|
@ -34,3 +31,6 @@
|
||||||
state: "{{ item.state | default('present') }}"
|
state: "{{ item.state | default('present') }}"
|
||||||
loop: "{{ minio_users }}"
|
loop: "{{ minio_users }}"
|
||||||
no_log: true
|
no_log: true
|
||||||
|
|
||||||
|
# Bug: delegate_to: localhost
|
||||||
|
# in ansible-devspace wird das Python Paket "minio" nicht gefunden
|
||||||
|
|
|
@ -27,12 +27,12 @@
|
||||||
loop: "{{ minio_buckets }}"
|
loop: "{{ minio_buckets }}"
|
||||||
|
|
||||||
- name: "setup policies (ro)"
|
- name: "setup policies (ro)"
|
||||||
ansible.builtin.command: "{{ minio_client_bin }} --dp admin policy create {{ minio_root_alias }} {{ item.name }}_ro {{ minio_config_dir }}/{{ item.name }}_ro"
|
ansible.builtin.command: "{{ minio_client_bin }} --disable-pager admin policy create {{ minio_root_alias }} {{ item.name }}_ro {{ minio_config_dir }}/{{ item.name }}_ro"
|
||||||
loop: "{{ minio_buckets }}"
|
loop: "{{ minio_buckets }}"
|
||||||
changed_when: false # Befehl gibt immer "Created policy `testbucket3_ro` successfully." aus, unabhängig ob sie schon existiert oder nicht.
|
changed_when: false # Befehl gibt immer "Created policy `testbucket3_ro` successfully." aus, unabhängig ob sie schon existiert oder nicht.
|
||||||
|
|
||||||
- name: "setup policies (rw)"
|
- name: "setup policies (rw)"
|
||||||
ansible.builtin.command: "{{ minio_client_bin }} --dp admin policy create {{ minio_root_alias }} {{ item.name }}_rw {{ minio_config_dir }}/{{ item.name }}_rw"
|
ansible.builtin.command: "{{ minio_client_bin }} --disable-pager admin policy create {{ minio_root_alias }} {{ item.name }}_rw {{ minio_config_dir }}/{{ item.name }}_rw"
|
||||||
loop: "{{ minio_buckets }}"
|
loop: "{{ minio_buckets }}"
|
||||||
changed_when: false # Befehl gibt immer "Created policy `testbucket3_ro` successfully." aus, unabhängig ob sie schon existiert oder nicht.
|
changed_when: false # Befehl gibt immer "Created policy `testbucket3_ro` successfully." aus, unabhängig ob sie schon existiert oder nicht.
|
||||||
|
|
||||||
|
@ -42,5 +42,3 @@
|
||||||
state: absent
|
state: absent
|
||||||
loop: "{{ minio_buckets }}"
|
loop: "{{ minio_buckets }}"
|
||||||
when: '"absent" in item.state'
|
when: '"absent" in item.state'
|
||||||
|
|
||||||
# deletata to localhost
|
|
||||||
|
|
Loading…
Reference in a new issue