Skip to content

Commit

Permalink
fix minio docker-compose (#327)
Browse files Browse the repository at this point in the history
  • Loading branch information
regis-leray authored Jul 14, 2022
1 parent 79b7524 commit c1ba528
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 11 deletions.
19 changes: 9 additions & 10 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,38 @@ version: "3.7"

services:
minio:
image: minio/minio
image: quay.io/minio/minio
ports:
- "9000:9000"
- "9001:9001"
volumes:
- ./minio/data:/data
environment:
- MINIO_ACCESS_KEY=TESTKEY
- MINIO_SECRET_KEY=TESTSECRET
- MINIO_ROOT_USER=TESTKEY
- MINIO_ROOT_PASSWORD=TESTSECRET
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 30s
timeout: 20s
retries: 3

command: server --compat /data
command: server /data --console-address ":9001"

mc:
image: minio/mc
image: quay.io/minio/mc
volumes:
- ./minio/export:/export
depends_on:
- minio
environment:
- MINIO_ACCESS_KEY=TESTKEY
- MINIO_SECRET_KEY=TESTSECRET
- MINIO_ROOT_USER=TESTKEY
- MINIO_ROOT_PASSWORD=TESTSECRET
entrypoint: >
/bin/sh -c "
echo Waiting for minio service to start...;
curl --retry 10 --retry-delay 10 -s -o /dev/null http://minio:9000/minio/health/live
echo Minio is started;
/usr/bin/mc config host add my-minio http://minio:9000 $${MINIO_ACCESS_KEY} $${MINIO_SECRET_KEY};
/usr/bin/mc config host add my-minio http://minio:9000 $${MINIO_ROOT_USER} $${MINIO_ROOT_PASSWORD};
/usr/bin/mc mb -p my-minio/bucket-1;
/usr/bin/mc mirror export/ my-minio/bucket-1;
"
2 changes: 1 addition & 1 deletion src/test/scala/zio/s3/S3Test.scala
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ object S3LiveSpec extends ZIOSpecDefault {
.live(
Region.CA_CENTRAL_1,
AwsBasicCredentials.create("TESTKEY", "TESTSECRET"),
Some(URI.create("http://localhost:9000"))
Some(URI.create("http://127.0.0.1:9000"))
)
.mapError(TestFailure.die)

Expand Down

0 comments on commit c1ba528

Please sign in to comment.