Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Minio to github actions to use in test suite #77

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,12 @@ jobs:
go-version: ${{ matrix.go }}
- name: Build
run: go build -v ./...
- name: Start MinIO (emulates S3)
run: |
wget -q https://dl.min.io/server/minio/release/linux-amd64/minio
chmod +x minio
export MINIO_ROOT_USER=minioadmin
export MINIO_ROOT_PASSWORD=minioadmin
./minio server /tmp/minio --address 127.0.0.1:4730 --quiet &
- name: Test
run: ./test.sh
4 changes: 2 additions & 2 deletions test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
if [ ! -z "$SIMPLEBLOB_TEST_S3_CONFIG" ]; then
echo "* Using existing SIMPLEBLOB_TEST_S3_CONFIG=$SIMPLEBLOB_TEST_S3_CONFIG"
elif curl -v --connect-timeout 2 http://localhost:4730/ 2>&1 | grep --silent MinIO ; then
echo "* Using MinIO in Docker Compose for tests"
echo "* Using MinIO on localhost for tests"
export SIMPLEBLOB_TEST_S3_CONFIG="$PWD/docker/test-minio.json"
else
echo "* MinIO not running in Docker Compose, skipping S3 tests"
echo "* MinIO not running on localhost, skipping S3 tests"
fi

set -ex
Expand Down
Loading