This commit is contained in:
Alexandre
2025-07-16 09:09:29 +02:00
committed by GitHub
parent 47a87d3f4f
commit a2ec42c05a
4 changed files with 55 additions and 1 deletions

View File

@@ -63,3 +63,22 @@ SQL
bashio::log.info "Internal Postgres ready."
done
#################
# Minio startup #
#################
MINIO_USER="$(bashio::config 'MINIO_ROOT_USER')"
MINIO_PASS="$(bashio::config 'MINIO_ROOT_PASSWORD')"
S3_BUCKET="$(bashio::config 'S3_BUCKET')"
bashio::log.info "Waiting for MinIO API…"
until /usr/local/bin/mc alias set h0 http://localhost:3200 "${MINIO_USER}" "${MINIO_PASS}" 2>/dev/null; do
sleep 1
done
bashio::log.info "Ensuring bucket ${S3_BUCKET} exists…"
/usr/local/bin/mc mb -p "h0/${S3_BUCKET}" || true
bashio::log.info "MinIO bucket ready."
sleep infinity