sendou.ink/compose.yaml
Kalle ef368e9fa2 Fix flaky art upload E2E test by verifying MinIO bucket
The test failed intermittently in CI with a 500 from POST /art/new.data:
the sendou bucket was missing for the whole run, so the upload threw
NoSuchBucket. art.spec.ts is the only e2e test that writes to S3, which
is why it was the only casualty.
2026-08-03 16:08:27 +03:00

44 lines
1.7 KiB
YAML

services:
minio:
image: "minio/minio:latest"
ports:
- "9000:9000"
- "9001:9001"
environment:
MINIO_ROOT_USER: minio-user
MINIO_ROOT_PASSWORD: minio-password
entrypoint: >
/bin/sh -c '
isAlive() { curl -sf http://127.0.0.1:9000/minio/health/live; } # check if Minio is alive
minio $$0 "$$@" --quiet & echo $$! > /tmp/minio.pid # start Minio in the background
while ! isAlive; do sleep 0.1; done # wait until Minio is alive
until mc alias set minio http://127.0.0.1:9000 minio-user minio-password; do sleep 0.5; done # setup Minio client (health/live can answer before credentials are accepted)
until mc mb --ignore-existing minio/sendou; do sleep 0.5; done # create a test bucket
until mc anonymous set public minio/sendou; do sleep 0.5; done # make the test bucket public
kill -s INT $$(cat /tmp/minio.pid) && rm /tmp/minio.pid # stop Minio
while isAlive; do sleep 0.1; done # wait until Minio is stopped
exec minio $$0 "$$@" # start Minio in the foreground
'
volumes:
- ~/minio/data:/data
command: server /data --console-address ":9001"
skalop:
image: ghcr.io/sendou-ink/skalop:latest
pull_policy: always
ports:
- "5900:5900"
environment:
- REDIS_URL=${REDIS_URL}
- SKALOP_TOKEN=${SKALOP_TOKEN}
- SESSION_SECRET=${SESSION_SECRET}
- PORT=5900
- NODE_ENV=development
depends_on:
- redis
restart: unless-stopped
redis:
image: redis:alpine
restart: unless-stopped