-
Notifications
You must be signed in to change notification settings - Fork 13
56 lines (48 loc) · 1.54 KB
/
test.storage-s3-compatible.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: S3 Compatible
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
test:
name: Test
env:
_access_key: minioadmin
_secret_key: minioadmin
_bucket: test-bucket
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [22.x]
steps:
- name: Setup minio
run: >-
docker run -d -p 9000:9000 --name minio
-e MINIO_ACCESS_KEY=${{env._access_key}}
-e MINIO_SECRET_KEY=${{env._secret_key}}
-v /tmp/data:/data -v /tmp/config:/root/.minio
minio/minio server /data
- run: wget https://dl.min.io/client/mc/release/linux-amd64/mc
- run: chmod +x ./mc
- run: ./mc alias set myminio http://127.0.0.1:9000 ${{env._access_key}} ${{env._secret_key}}
- run: ./mc mb --ignore-existing myminio/${{env._bucket}}
- name: Check out repository code
uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Install dependencies
working-directory: ./packages/storage/storage-s3-compatible
run: npm ci
- name: Test
run: npm test
working-directory: ./packages/storage/storage-s3-compatible
env:
ACCESS_KEY_ID: ${{env._access_key}}
SECRET_ACCESS_KEY: ${{env._secret_key}}
BUCKET: ${{env._bucket}}
ENDPOINT: http://127.0.0.1:9000
REGION: us-east-1