This commit is contained in:
Senko-san
2026-06-08 12:49:45 +03:00
commit 1b251869c4
21 changed files with 1404 additions and 0 deletions
+26
View File
@@ -0,0 +1,26 @@
# -- built-in S3 (MinIO) + one-shot bucket creation ----------------------
minio:
image: minio/minio:latest
restart: unless-stopped
command: server /data --console-address ":9001"
environment:
MINIO_ROOT_USER: ${S3_ACCESS_KEY}
MINIO_ROOT_PASSWORD: ${S3_SECRET_KEY}
volumes:
- miniodata:/data
# Waits for MinIO to accept connections, then creates the bucket. Runs once
# (restart: no) and exits 0 — `compose up --wait` treats that as complete.
minio-setup:
image: minio/mc:latest
restart: "no"
depends_on:
- minio
entrypoint: >
/bin/sh -c "
until mc alias set mcma http://minio:9000 ${S3_ACCESS_KEY} ${S3_SECRET_KEY}; do
echo 'waiting for minio...'; sleep 2;
done &&
mc mb --ignore-existing mcma/${S3_BUCKET} &&
echo 'bucket ready'
"