diff --git a/Makefile b/Makefile index a76a3e36..43fd2463 100644 --- a/Makefile +++ b/Makefile @@ -7,6 +7,8 @@ ROOTDIR=$(dir $(abspath $(lastword $(MAKEFILE_LIST)))) VERSION ?= $(shell git describe --match 'v[0-9]*' --dirty='.m' --always) REVISION ?= $(shell git rev-parse HEAD)$(shell if ! git diff --no-ext-diff --quiet --exit-code; then echo .m; fi) +# default compose command +COMPOSE=docker compose PKG=github.com/distribution/distribution/v3 @@ -126,14 +128,14 @@ start-cloud-storage: ## start local cloud storage (minio) .PHONY: stop-cloud-storage stop-cloud-storage: ## stop local cloud storage (minio) - docker compose -f tests/docker-compose-storage.yml down + $(COMPOSE) -f tests/docker-compose-storage.yml down .PHONY: reset-cloud-storage reset-cloud-storage: ## reset (stop, delete, start) local cloud storage (minio) - docker compose -f tests/docker-compose-storage.yml down + $(COMPOSE) -f tests/docker-compose-storage.yml down @mkdir -p tests/miniodata/distribution @rm -rf tests/miniodata/distribution/* tests/miniodata/.minio.sys - docker compose -f tests/docker-compose-storage.yml up minio minio-init -d + $(COMPOSE) -f tests/docker-compose-storage.yml up minio minio-init -d .PHONY: run-s3-tests run-s3-tests: ## run S3 storage driver integration tests diff --git a/tests/docker-compose-storage.yml b/tests/docker-compose-storage.yml index 1bb454ab..7377abcd 100644 --- a/tests/docker-compose-storage.yml +++ b/tests/docker-compose-storage.yml @@ -25,7 +25,7 @@ services: /bin/bash -c " /usr/bin/mc config host add minio http://minio:9000 $${MINIO_ROOT_USER} $${MINIO_ROOT_PASSWORD} && ( /usr/bin/mc stat minio/images-local || /usr/bin/mc mb minio/images-local - ) && /usr/bin/mc anonymous set public minio/images-local && /usr/bin/mc admin trace --path " + ) && /usr/bin/mc anonymous set public minio/images-local" environment: MINIO_ROOT_USER: distribution MINIO_ROOT_PASSWORD: password