mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-05-08 12:34:43 +02:00
ci: add MinIO integration test job for S3-compatible mode
This commit is contained in:
parent
2fdcfa66eb
commit
63b25380d8
1 changed files with 59 additions and 0 deletions
59
.github/workflows/build.yml
vendored
59
.github/workflows/build.yml
vendored
|
|
@ -227,3 +227,62 @@ jobs:
|
|||
run: |
|
||||
echo "### :tada: Checks Passed!" >> "${GITHUB_STEP_SUMMARY}"
|
||||
echo "" >> "${GITHUB_STEP_SUMMARY}"
|
||||
|
||||
s3-compatible-minio:
|
||||
name: S3-Compatible Integration (MinIO)
|
||||
runs-on: ubuntu-24.04
|
||||
timeout-minutes: 45
|
||||
|
||||
steps:
|
||||
- name: "Install dependencies Ubuntu"
|
||||
run: sudo apt-get update && sudo apt-get install -y --no-install-recommends curl openssl build-essential libmariadb-dev-compat libpq-dev libssl-dev pkg-config
|
||||
|
||||
- name: "Checkout"
|
||||
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 #v6.0.0
|
||||
with:
|
||||
persist-credentials: false
|
||||
fetch-depth: 0
|
||||
|
||||
- name: "Install rust-toolchain version"
|
||||
uses: dtolnay/rust-toolchain@f7ccc83f9ed1e5b9c81d8a67d7ad1a747e22a561 # master @ Dec 16, 2025, 6:11 PM GMT+1
|
||||
with:
|
||||
toolchain: stable
|
||||
|
||||
- name: "Show environment"
|
||||
run: |
|
||||
rustc -vV
|
||||
cargo -vV
|
||||
|
||||
- name: Rust Caching
|
||||
uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2.8.2
|
||||
with:
|
||||
prefix-key: "v2025.09-rust"
|
||||
|
||||
- name: Start MinIO
|
||||
run: |
|
||||
docker run -d --name minio \
|
||||
-p 9000:9000 \
|
||||
-e MINIO_ROOT_USER=minioadmin \
|
||||
-e MINIO_ROOT_PASSWORD=minioadmin \
|
||||
quay.io/minio/minio:RELEASE.2025-07-23T15-54-02Z \
|
||||
server /data --console-address ":9001"
|
||||
|
||||
for i in {1..30}; do
|
||||
if curl -fsS "http://127.0.0.1:9000/minio/health/live" >/dev/null; then
|
||||
break
|
||||
fi
|
||||
sleep 1
|
||||
done
|
||||
|
||||
docker run --rm --network host quay.io/minio/mc:RELEASE.2025-06-13T11-33-47Z \
|
||||
sh -c "mc alias set local http://127.0.0.1:9000 minioadmin minioadmin && mc mb --ignore-existing local/vaultwarden-test"
|
||||
|
||||
- name: Run MinIO integration test
|
||||
env:
|
||||
VW_S3_MINIO_ENDPOINT: "http://127.0.0.1:9000"
|
||||
VW_S3_MINIO_BUCKET: "vaultwarden-test"
|
||||
VW_S3_MINIO_ROOT: "/vaultwarden-integration"
|
||||
VW_S3_MINIO_ACCESS_KEY: "minioadmin"
|
||||
VW_S3_MINIO_SECRET_KEY: "minioadmin"
|
||||
run: |
|
||||
cargo test --profile ci --features sqlite,s3 test_s3_minio_integration_put_get_delete -- --ignored
|
||||
|
|
|
|||
Loading…
Reference in a new issue