feat: add minio machine

This commit is contained in:
Alexander Navarro 2025-02-10 16:09:34 -03:00
parent fd44bd54a5
commit c48fdfe84f
5 changed files with 54 additions and 7 deletions

34
playbooks/storage/s3.yaml Normal file
View file

@ -0,0 +1,34 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/ansible/ansible-lint/refs/heads/main/src/ansiblelint/schemas/playbook.json
---
- name: Setup S3 storage
hosts: s3
tasks:
- name: Install MinIO
become: true
apk:
name: minio
update_cache: yes
- name: Create MinIO directories
become: true
file:
path: /data/minio
state: directory
owner: minio
group: minio
mode: '0755'
- name: Configure MinIO
copy:
dest: /etc/default/minio
content: |
MINIO_VOLUMES="/data/minio/"
MINIO_OPTS="--address :9000"
- name: Enable and start MinIO service
service:
name: minio
enabled: yes
state: started