mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-24 21:26:28 +00:00
Merge pull request #141 from rustfs/nugine/ci-s3s-e2e
ci(e2e): run s3s-e2e tests
This commit is contained in:
+83
-35
@@ -2,8 +2,14 @@ name: E2E
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
schedule:
|
||||||
|
- cron: '0 0 * * 0' # at midnight of each sunday
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ "main" ]
|
branches:
|
||||||
|
- main
|
||||||
|
|
||||||
env:
|
env:
|
||||||
CARGO_TERM_COLOR: always
|
CARGO_TERM_COLOR: always
|
||||||
@@ -24,50 +30,92 @@ jobs:
|
|||||||
cancel_others: true
|
cancel_others: true
|
||||||
paths_ignore: '["*.md"]'
|
paths_ignore: '["*.md"]'
|
||||||
|
|
||||||
e2e:
|
s3s-e2e:
|
||||||
# See this url if required matrix jobs are hanging
|
|
||||||
# https://github.com/fkirc/skip-duplicate-actions#how-to-use-skip-check-with-required-matrix-jobs
|
|
||||||
needs: skip-check
|
needs: skip-check
|
||||||
if: needs.skip-check.outputs.should_skip != 'true'
|
if: needs.skip-check.outputs.should_skip != 'true'
|
||||||
|
|
||||||
timeout-minutes: 30
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
timeout-minutes: 20
|
||||||
matrix:
|
|
||||||
rust:
|
|
||||||
- stable
|
|
||||||
# - nightly
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: dtolnay/rust-toolchain@stable
|
||||||
|
- uses: Swatinem/rust-cache@v2
|
||||||
- uses: arduino/setup-protoc@v3
|
- uses: arduino/setup-protoc@v3
|
||||||
with:
|
with:
|
||||||
version: "27.0"
|
version: "27.0"
|
||||||
|
|
||||||
- uses: Nugine/setup-flatc@v1
|
- uses: Nugine/setup-flatc@v1
|
||||||
with:
|
with:
|
||||||
version: "24.3.25"
|
version: "24.3.25"
|
||||||
|
|
||||||
- uses: actions/checkout@v4
|
- name: Build binaries
|
||||||
|
|
||||||
- name: toolchain
|
|
||||||
uses: dtolnay/rust-toolchain@master
|
|
||||||
with:
|
|
||||||
toolchain: ${{ matrix.rust }}
|
|
||||||
# components: rustfmt, clippy
|
|
||||||
|
|
||||||
- uses: Swatinem/rust-cache@v2
|
|
||||||
with:
|
|
||||||
cache-on-failure: true
|
|
||||||
|
|
||||||
- name: run fs start
|
|
||||||
working-directory: .
|
|
||||||
run: |
|
run: |
|
||||||
nohup make e2e-server &
|
touch rustfs/build.rs
|
||||||
|
cargo build -p rustfs --bins
|
||||||
- name: run fs test
|
|
||||||
working-directory: .
|
|
||||||
run: |
|
|
||||||
make probe-e2e
|
|
||||||
|
|
||||||
- name: e2e test
|
- name: Install s3s-e2e
|
||||||
run: cargo test -p e2e_test --lib
|
run: |
|
||||||
|
cargo install s3s-e2e --git https://github.com/Nugine/s3s.git
|
||||||
|
s3s-e2e --version
|
||||||
|
|
||||||
|
- name: Run tests
|
||||||
|
run: |
|
||||||
|
export SKIP_BUILD=1
|
||||||
|
nohup ./scripts/run.sh &
|
||||||
|
sleep 3
|
||||||
|
|
||||||
|
export AWS_ACCESS_KEY_ID=rustfsadmin
|
||||||
|
export AWS_SECRET_ACCESS_KEY=rustfsadmin
|
||||||
|
export AWS_REGION=us-east-1
|
||||||
|
export AWS_ENDPOINT_URL=http://localhost:9000
|
||||||
|
export RUST_LOG="s3s_e2e=debug,s3s_test=info,s3s=debug"
|
||||||
|
export RUST_BACKTRACE=full
|
||||||
|
s3s-e2e
|
||||||
|
killall rustfs
|
||||||
|
|
||||||
|
### Temporarily disabled because it is not working
|
||||||
|
# e2e:
|
||||||
|
# # See this url if required matrix jobs are hanging
|
||||||
|
# # https://github.com/fkirc/skip-duplicate-actions#how-to-use-skip-check-with-required-matrix-jobs
|
||||||
|
# needs: skip-check
|
||||||
|
# if: needs.skip-check.outputs.should_skip != 'true'
|
||||||
|
|
||||||
|
# timeout-minutes: 30
|
||||||
|
# runs-on: ubuntu-latest
|
||||||
|
# strategy:
|
||||||
|
# matrix:
|
||||||
|
# rust:
|
||||||
|
# - stable
|
||||||
|
# # - nightly
|
||||||
|
|
||||||
|
# steps:
|
||||||
|
# - uses: arduino/setup-protoc@v3
|
||||||
|
# with:
|
||||||
|
# version: "27.0"
|
||||||
|
|
||||||
|
# - uses: Nugine/setup-flatc@v1
|
||||||
|
# with:
|
||||||
|
# version: "24.3.25"
|
||||||
|
|
||||||
|
# - uses: actions/checkout@v4
|
||||||
|
|
||||||
|
# - name: toolchain
|
||||||
|
# uses: dtolnay/rust-toolchain@master
|
||||||
|
# with:
|
||||||
|
# toolchain: ${{ matrix.rust }}
|
||||||
|
# # components: rustfmt, clippy
|
||||||
|
|
||||||
|
# - uses: Swatinem/rust-cache@v2
|
||||||
|
# with:
|
||||||
|
# cache-on-failure: true
|
||||||
|
|
||||||
|
# - name: run fs start
|
||||||
|
# working-directory: .
|
||||||
|
# run: |
|
||||||
|
# nohup make e2e-server &
|
||||||
|
|
||||||
|
# - name: run fs test
|
||||||
|
# working-directory: .
|
||||||
|
# run: |
|
||||||
|
# make probe-e2e
|
||||||
|
|
||||||
|
# - name: e2e test
|
||||||
|
# run: cargo test -p e2e_test --lib
|
||||||
|
|||||||
+6
-2
@@ -1,4 +1,8 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash -e
|
||||||
|
|
||||||
|
if [ -z "$SKIP_BUILD" ]; then
|
||||||
|
cargo build -p rustfs --bins
|
||||||
|
fi
|
||||||
|
|
||||||
current_dir=$(pwd)
|
current_dir=$(pwd)
|
||||||
|
|
||||||
@@ -29,5 +33,5 @@ fi
|
|||||||
# --domain-name 127.0.0.1:9010 \
|
# --domain-name 127.0.0.1:9010 \
|
||||||
# "$DATA_DIR_ARG"
|
# "$DATA_DIR_ARG"
|
||||||
|
|
||||||
cargo run "$DATA_DIR_ARG"
|
./target/debug/rustfs "$DATA_DIR_ARG"
|
||||||
# cargo run ./target/volume/test
|
# cargo run ./target/volume/test
|
||||||
Reference in New Issue
Block a user