From 3d3655a95e877b7c965bcb811751daf091698591 Mon Sep 17 00:00:00 2001 From: Adrien Bouvais Date: Sat, 15 Aug 2026 11:03:01 +0200 Subject: [PATCH] Prevent error if IAM already set --- charts/tenant/templates/minio-setup.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/charts/tenant/templates/minio-setup.yaml b/charts/tenant/templates/minio-setup.yaml index 67f0750..04b22d1 100644 --- a/charts/tenant/templates/minio-setup.yaml +++ b/charts/tenant/templates/minio-setup.yaml @@ -94,5 +94,6 @@ spec: # The rest remains the same... mc admin policy create minioadmin {{ .Values.name }}-policy /tmp/policy.json || mc admin policy update minioadmin {{ .Values.name }}-policy /tmp/policy.json - mc admin policy attach minioadmin {{ .Values.name }}-policy --user="$TENANT_USER" + # Good enough for now, would need better error handeling + mc admin policy attach minioadmin {{ .Values.name }}-policy --user="$TENANT_USER" || echo "Policy already attached, skipping." echo "MinIO setup completed for {{ .Values.name }}"