Repository navigation
feat: add seaweedfs unit test workflow - #1608
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
WalkthroughAdds a GitHub Actions workflow that starts SeaweedFS (S3), Vault, Postgres, and OpenFGA; conditionally configures cloud credentials; runs DB migrations; executes cargo-nextest tests with appropriate envs; captures diagnostics; uploads JUnit artifacts; and runs workspace doctests. ChangesSeaweedFS CI Workflow
Sequence Diagram(s)sequenceDiagram
participant GH as GitHub Actions
participant Repo as Repository
participant Seaweed as SeaweedFS
participant Vault as Vault
participant PG as Postgres
participant OpenFGA as OpenFGA
participant Cloud as Cloud Providers
GH->>Repo: checkout repository
GH->>Seaweed: start SeaweedFS (S3 endpoint)
GH->>Seaweed: poll S3 health and create `tests` bucket
GH->>Vault: start Vault container and configure auth/policy
GH->>PG: start Postgres service and create DB
GH->>OpenFGA: start OpenFGA Docker
GH->>Cloud: conditional Azure login / write GCS credentials
GH->>Repo: install Rust toolchain, cargo-nextest, sqlx-cli
GH->>Repo: run sqlx migrations against Postgres
GH->>Repo: run cargo-nextest with env for PG, Vault, Seaweed, OpenFGA, Cloud
Repo-->>GH: produce JUnit results, logs, and artifacts
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 5
🤖 Fix all issues with AI agents
In @.github/workflows/seaweedfs.yml:
- Around line 150-158: The "Setup vault" GitHub Actions step runs apt install
commands without non-interactive flags and can hang CI; update the commands in
that step (the two apt install invocations around "sudo apt install gpg wget"
and "sudo apt update && sudo apt install vault") to include the
assume-yes/noninteractive flags (e.g., -y or -yqq and keep
DEBIAN_FRONTEND=noninteractive) so installs won’t prompt and the runner won't
block; modify the commands referenced in the "Setup vault" step accordingly.
- Around line 59-63: The Checkout SeaweedFS step is unpinned and can break CI;
update the "Checkout SeaweedFS" job step that uses actions/checkout@v6
(repository: seaweedfs/seaweedfs, path: seaweedfs) to include a pinned ref by
adding a with: ref: "<tag-or-commit-sha>" entry (choose a stable tag or specific
commit SHA) so the workflow checks out a reproducible version instead of the
default branch HEAD.
- Around line 128-137: The "Determine nextest profile" step incorrectly checks
github.event.pull_request.head.repo.full_name which is empty on push events,
causing NEXTEST_PROFILE to default to ci_no_secrets; change the logic in that
step to first test github.event_name (or whether github.event.pull_request is
defined) and only use the pull_request fork check when the event is a
pull_request, otherwise set NEXTEST_PROFILE=ci for non-PR events (e.g., pushes
to main) so that pushes get the full "ci" profile; update references to
NEXTEST_PROFILE and the existing github.event.pull_request.head.repo.full_name
check accordingly in the Determine nextest profile step.
- Around line 220-224: Update the "Upload junit" step so it always runs and
accepts any profile directory: add the workflow conditional if: always() to the
step that uses actions/upload-artifact@v5, and change the artifact path from the
hardcoded target/nextest/ci/junit.xml to a glob like target/nextest/*/junit.xml
(or target/nextest/**/junit.xml) so junit files from ci or ci_no_secrets are
uploaded on failure as well as success.
- Around line 169-219: The Test job currently hardcodes a large env block for
seaweedFS-specific variables; refactor it to follow the project's dynamic
test-matrix pattern used by integration_test_matrix.yml and
integration_test_workflow.yml by replacing the hardcoded LAKEKEEPER_TEST__* /
AWS_* / GCS_* / R2 env entries with inputs derived from a matrix/test name
(e.g., pass a test identifier like "seaweedfs-<version>" into the shared
workflow) and map the matrix entry to the runtime envs in the shared workflow;
update the "Test" step (uses: nick-fields/retry...) to accept those
matrix-provided envs instead of hardcoding, and ensure secrets remain referenced
via ${{ secrets.* }} in the shared workflow so configuration is dynamic and
version-agnostic.
🧹 Nitpick comments (4)
.github/workflows/seaweedfs.yml (4)
29-29: Vault service image uses unpinnedlatesttag.
hashicorp/vault:latestcan introduce unexpected breaking changes. Consider pinning to a specific version (e.g.,hashicorp/vault:1.15) for reproducible CI runs.
75-82:sleep 5is redundant given the dedicated health-check step that follows.The next step ("Wait for SeaweedFS S3 to be healthy") already polls for up to 30 seconds. The
sleep 5adds unnecessary wall-clock time to every run. Consider removing it or reducing it tosleep 1if you want to avoid the initial curl failure noise.
113-115: GCS credential write can break if the secret contains single quotes.
echo '${{ secrets.GCS_CREDENTIAL }}'will fail if the secret value contains literal'characters. A heredoc is more robust.Proposed fix
- name: Write gcp credential to file if: ${{ env.GCS_CREDENTIAL != '' }} - run: echo '${{ secrets.GCS_CREDENTIAL }}' > /tmp/gcs.json + run: | + cat <<'EOF' > /tmp/gcs.json + ${{ secrets.GCS_CREDENTIAL }} + EOF shell: bash
167-167: OpenFGA container is unpinned and uses a fire-and-forgetdocker run.
openfga/openfga:v1.8has no digest pin (minor risk), and there's no health check before tests start. If OpenFGA takes a moment to become ready, tests relying on it could be flaky.Consider adding a health-check poll similar to the SeaweedFS one:
- name: Wait for OpenFGA run: | for i in {1..15}; do curl -sf http://localhost:35081/healthz && exit 0 sleep 1 done echo "OpenFGA did not become healthy" exit 1
| - name: Determine nextest profile | ||
| run: | | ||
| if [[ "${{ github.event.pull_request.head.repo.full_name }}" == "${{ github.repository }}" ]]; then | ||
| # PR is made off this repo, so workflows have access to secrets and the entire suite | ||
| # can be run. | ||
| echo "NEXTEST_PROFILE=ci" >> $GITHUB_ENV | ||
| else | ||
| # PR is made off a fork, so secrets are not available in ci workflows. | ||
| echo "NEXTEST_PROFILE=ci_no_secrets" >> $GITHUB_ENV | ||
| fi |
There was a problem hiding this comment.
Nextest profile defaults to ci_no_secrets on push events to main.
On non-PR events (e.g., push to main), github.event.pull_request.head.repo.full_name is empty, so the condition never matches and the profile falls through to ci_no_secrets. Pushes to main have full access to secrets and should use the ci profile.
Proposed fix
- name: Determine nextest profile
run: |
- if [[ "${{ github.event.pull_request.head.repo.full_name }}" == "${{ github.repository }}" ]]; then
- # PR is made off this repo, so workflows have access to secrets and the entire suite
- # can be run.
+ if [[ "${{ github.event_name }}" != "pull_request" || "${{ github.event.pull_request.head.repo.full_name }}" == "${{ github.repository }}" ]]; then
+ # Non-PR events (push, workflow_dispatch) have access to secrets, as do PRs from this repo.
echo "NEXTEST_PROFILE=ci" >> $GITHUB_ENV
else
# PR is made off a fork, so secrets are not available in ci workflows.
echo "NEXTEST_PROFILE=ci_no_secrets" >> $GITHUB_ENV
fi🤖 Prompt for AI Agents
In @.github/workflows/seaweedfs.yml around lines 128 - 137, The "Determine
nextest profile" step incorrectly checks
github.event.pull_request.head.repo.full_name which is empty on push events,
causing NEXTEST_PROFILE to default to ci_no_secrets; change the logic in that
step to first test github.event_name (or whether github.event.pull_request is
defined) and only use the pull_request fork check when the event is a
pull_request, otherwise set NEXTEST_PROFILE=ci for non-PR events (e.g., pushes
to main) so that pushes get the full "ci" profile; update references to
NEXTEST_PROFILE and the existing github.event.pull_request.head.repo.full_name
check accordingly in the Determine nextest profile step.
|
@coderabbitai full review |
✅ Actions performedFull review triggered. |
|
@chrislusf, once this is in, WDYT replacing our "examples" docker compose too (top level repo folder). I believe those have higher visibility. |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Fix all issues with AI agents
In @.github/workflows/seaweedfs.yml:
- Around line 192-193: The "Setup openfga" step starts OpenFGA with "docker run
-d -p 35081:8081 openfga/openfga:v1.8 run" but has no readiness check; add a
follow-up step that polls the container until OpenFGA is ready (e.g., loop with
curl against http://localhost:35081/health or an equivalent readiness endpoint,
or test TCP connectivity on port 35081) with a bounded timeout and retry
interval, and fail the job if the service doesn't become healthy in time so
downstream test steps won't run against a not-yet-ready OpenFGA.
- Around line 61-66: Replace the unstable branch pin in the GitHub Actions
checkout step for "Checkout SeaweedFS" by using a specific commit SHA (or a
release tag) instead of ref: allow-no-role-arn; update the actions/checkout@v6
step to set ref to 006a5b55468909e443ac4d81a9fcb48e5015a682 (or a released tag)
to ensure reproducible CI runs.
🧹 Nitpick comments (3)
.github/workflows/seaweedfs.yml (3)
30-31: Pin the Vault service image to a specific version.Using
hashicorp/vault:latestmeans any upstream release can silently break this workflow. Pin to a known-good version (e.g.,hashicorp/vault:1.15) for reproducibility, consistent with the pinned Postgres image on line 43.Proposed fix
vault: - image: hashicorp/vault:latest + image: hashicorp/vault:1.15
139-142: Prefer env-var indirection when writing secrets to files.Direct interpolation of
${{ secrets.GCS_CREDENTIAL }}into the shell command can break if the secret value contains characters meaningful to the shell (e.g., single quotes, backticks). Using an environment variable is more robust:Proposed fix
- name: Write gcp credential to file if: ${{ env.GCS_CREDENTIAL != '' }} - run: echo '${{ secrets.GCS_CREDENTIAL }}' > /tmp/gcs.json - shell: bash + run: printenv GCS_CRED > /tmp/gcs.json + shell: bash + env: + GCS_CRED: ${{ secrets.GCS_CREDENTIAL }}
4-11: Workflow triggers on all PRs with no path filter — consider scoping.This workflow builds SeaweedFS from source (Go compilation) and runs the full test suite, which is expensive. Triggering on every
pull_requestevent — including docs-only or CI-config changes — wastes runner minutes. Consider adding path filters or making itworkflow_dispatch-only until it's production-ready (this is a draft PR).Example: add path filters
pull_request: + paths: + - 'crates/**' + - 'Cargo.toml' + - 'Cargo.lock' + - '.github/workflows/seaweedfs.yml' workflow_dispatch:
| - name: Setup openfga | ||
| run: docker run -d -p 35081:8081 openfga/openfga:v1.8 run |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
# Read the workflow file to see the current setup and health checks
cd /tmp && git ls-files ".github/workflows/seaweedfs.yml" 2>/dev/null || echo "File path needs verification"
cat -n .github/workflows/seaweedfs.yml | sed -n '180,220p'Repository: lakekeeper/lakekeeper
Length of output: 174
🏁 Script executed:
# Search for health check patterns in the workflow
rg -n "healthz|health_check|healthcheck" .github/workflows/seaweedfs.ymlRepository: lakekeeper/lakekeeper
Length of output: 47
🏁 Script executed:
# Search for docker run commands to see all services and their setup
rg -n "docker run" .github/workflows/seaweedfs.yml -A 2Repository: lakekeeper/lakekeeper
Length of output: 162
🌐 Web query:
OpenFGA health check endpoint documentation API
💡 Result:
OpenFGA exposes a built-in health check via:
- HTTP:
GET /healthz(e.g.,curl -X GET $FGA_API_URL/healthz) which returns JSON like{"status":"SERVING"}(status can beUNKNOWN,SERVING,NOT_SERVING, orSERVICE_UNKNOWN). - gRPC:
grpc.health.v1.Health/Check(commonly probed withgrpcurl).
Both are wired to datastore connectivity/testing. [1]
Sources
[1] OpenFGA docs — “Configuring OpenFGA” (Health check section) (openfga.dev)
Citations:
🏁 Script executed:
# Search for seaweedfs.yml in the repository
fd -name "seaweedfs.yml" -o -name "*workflow*" | head -20Repository: lakekeeper/lakekeeper
Length of output: 295
🏁 Script executed:
# List all files in .github directory
fd . .github 2>/dev/null | head -30Repository: lakekeeper/lakekeeper
Length of output: 669
🏁 Script executed:
# Read the workflow file around lines 180-220
cat -n .github/workflows/seaweedfs.yml | sed -n '180,220p'Repository: lakekeeper/lakekeeper
Length of output: 2641
🏁 Script executed:
# Search for all health check patterns in the workflow
rg -n "health" .github/workflows/seaweedfs.yml -i -B 1 -A 1Repository: lakekeeper/lakekeeper
Length of output: 967
🏁 Script executed:
# Search for all docker run commands to see service setup patterns
rg -n "docker run" .github/workflows/seaweedfs.yml -B 1 -A 2Repository: lakekeeper/lakekeeper
Length of output: 194
No health/readiness check after starting OpenFGA.
All other services in this workflow (Vault, Postgres, SeaweedFS) have health checks, but OpenFGA is started with docker run -d and immediately assumed ready. This can cause flaky test failures if OpenFGA hasn't finished starting when the test step begins.
Proposed fix — add a readiness probe
- name: Setup openfga
- run: docker run -d -p 35081:8081 openfga/openfga:v1.8 run
+ run: |
+ docker run -d -p 35081:8081 openfga/openfga:v1.8 run
+ for i in {1..30}; do
+ if curl -sf http://localhost:35081/healthz > /dev/null 2>&1; then
+ echo "OpenFGA is ready"
+ break
+ fi
+ echo "Waiting for OpenFGA..."
+ sleep 1
+ done🤖 Prompt for AI Agents
In @.github/workflows/seaweedfs.yml around lines 192 - 193, The "Setup openfga"
step starts OpenFGA with "docker run -d -p 35081:8081 openfga/openfga:v1.8 run"
but has no readiness check; add a follow-up step that polls the container until
OpenFGA is ready (e.g., loop with curl against http://localhost:35081/health or
an equivalent readiness endpoint, or test TCP connectivity on port 35081) with a
bounded timeout and retry interval, and fail the job if the service doesn't
become healthy in time so downstream test steps won't run against a
not-yet-ready OpenFGA.
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
.github/workflows/seaweedfs.yml (2)
31-31:⚠️ Potential issue | 🟠 Major | ⚡ Quick winPin the Vault service image (and the Vault CLI) to a specific, tested version instead of
hashicorp/vault:latest.
.github/workflows/seaweedfs.ymluseshashicorp/vault:latestfor thevaultservice, but later runsvault ...commands after installing the CLI viasudo apt ... apt install vault. Pin the service to an explicit tag/digest and align the installed CLI to the same release line (the repo already pinshashicorp/vault:1.21.4inunittests.yml).🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/seaweedfs.yml at line 31, Replace the unpinned Vault service image "image: hashicorp/vault:latest" with a specific tested tag (e.g. "hashicorp/vault:1.21.4") and ensure the workflow step that installs the Vault CLI uses the matching release line (pin the apt package or installation to 1.21.4) so the running service image and installed CLI are the same version; update any references to "vault" in the job that run vault ... commands to rely on the pinned version.
95-100:⚠️ Potential issue | 🟠 Major | ⚡ Quick winSet an AWS region for
aws s3api create-bucketThe
Create SeaweedFS Bucketstep provides credentials but noAWS_REGION/AWS_DEFAULT_REGION(or--region). With the AWS CLI, this can still causeYou must specify a regioneven when using--endpoint-urlto an S3-compatible server. AddAWS_REGION/AWS_DEFAULT_REGIONor pass--region(matching whatever region your later S3 calls use).🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/seaweedfs.yml around lines 95 - 100, The Create SeaweedFS Bucket step is missing a region, causing the AWS CLI to fail; update the env or command in that step by adding an AWS_REGION or AWS_DEFAULT_REGION environment variable (e.g., AWS_REGION: us-east-1) or by appending --region <region> to the aws s3api create-bucket command so the aws s3api create-bucket --bucket tests --endpoint-url http://127.0.0.1:8333 call has an explicit region; ensure the chosen region matches the region used by any later S3 calls.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.github/workflows/seaweedfs.yml:
- Around line 61-66: Replace the floating image tag in the "Start SeaweedFS
Docker Container" docker run step by pinning chrislusf/seaweedfs:latest to a
fixed tag or immutable digest (e.g., chrislusf/seaweedfs:<specific-tag> or
chrislusf/seaweedfs@sha256:<digest>) so CI uses a reproducible SeaweedFS
revision; update the image reference in that docker run command and, if
desirable, add a comment noting the chosen tag/digest or alternatively add
workflow steps to build SeaweedFS from source before running the container.
---
Outside diff comments:
In @.github/workflows/seaweedfs.yml:
- Line 31: Replace the unpinned Vault service image "image:
hashicorp/vault:latest" with a specific tested tag (e.g.
"hashicorp/vault:1.21.4") and ensure the workflow step that installs the Vault
CLI uses the matching release line (pin the apt package or installation to
1.21.4) so the running service image and installed CLI are the same version;
update any references to "vault" in the job that run vault ... commands to rely
on the pinned version.
- Around line 95-100: The Create SeaweedFS Bucket step is missing a region,
causing the AWS CLI to fail; update the env or command in that step by adding an
AWS_REGION or AWS_DEFAULT_REGION environment variable (e.g., AWS_REGION:
us-east-1) or by appending --region <region> to the aws s3api create-bucket
command so the aws s3api create-bucket --bucket tests --endpoint-url
http://127.0.0.1:8333 call has an explicit region; ensure the chosen region
matches the region used by any later S3 calls.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 9407c9f4-5924-49ab-9b7f-ae3ece5d082e
📒 Files selected for processing (1)
.github/workflows/seaweedfs.yml
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
.github/workflows/seaweedfs.yml (1)
153-167:⚠️ Potential issue | 🔴 Critical | ⚡ Quick winMissing
-yflag onapt installwill hang the CI runner.Lines 157 and 161 run
apt installwithout the-yflag. In a non-interactive CI environment,aptwill wait for confirmation and the step will hang until timeout. Line 145 correctly uses-yqq, but these lines do not.Note: A past review comment flagged this issue and was marked as addressed, but the fix appears incomplete.
Proposed fix
- name: Setup vault run: | export VAULT_ADDR=http://localhost:8200 export DEBIAN_FRONTEND=noninteractive - sudo apt update && sudo apt install gpg wget + sudo apt-get update && sudo apt-get install -yqq gpg wget --no-install-recommends wget -O- https://apt.releases.hashicorp.com/gpg | sudo gpg --dearmor -o /usr/share/keyrings/hashicorp-archive-keyring.gpg gpg --no-default-keyring --keyring /usr/share/keyrings/hashicorp-archive-keyring.gpg --fingerprint echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/hashicorp-archive-keyring.gpg] https://apt.releases.hashicorp.com $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/hashicorp.list - sudo apt update && sudo apt install vault + sudo apt-get update && sudo apt-get install -yqq vault --no-install-recommends🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/seaweedfs.yml around lines 153 - 167, The CI step that sets up Vault runs two apt installs without automatic confirmation: the commands "sudo apt update && sudo apt install gpg wget" and "sudo apt update && sudo apt install vault" should include the noninteractive install flag (e.g., -y or -yqq) so they don't prompt and hang; update those invocations in the "Setup vault" step to "sudo apt update && sudo apt install -y gpg wget" and "sudo apt update && sudo apt install -y vault" (or use -yqq for quieter output) while keeping DEBIAN_FRONTEND=noninteractive.
🧹 Nitpick comments (1)
.github/workflows/seaweedfs.yml (1)
119-125: 💤 Low valueConsider disabling default caching to mitigate cache-poisoning risk.
The
actions-rust-lang/setup-rust-toolchainaction enables caching by default. In fork PRs with write access to the cache, a malicious actor could potentially poison the cache. You can disable caching by settingcache: falseif this is a concern.However, the risk is relatively low for Rust dependency caches, and this pattern is commonly used. The action is already pinned to a SHA, which is good.
Optional: Disable caching
- name: Setup Rust toolchain and cache uses: actions-rust-lang/setup-rust-toolchain@46268bd060767258de96ed93c1251119784f2ab6 # v1 with: toolchain: ${{ env.RUST_TOOLCHAIN }} + cache: false env: RUST_CACHE_KEY_OS: rust-${{ env.RUST_TOOLCHAIN }}-cache-ubuntu-24.04🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/seaweedfs.yml around lines 119 - 125, The GitHub Actions step using actions-rust-lang/setup-rust-toolchain currently uses default caching; to mitigate cache-poisoning risk, update that step (the step referencing actions-rust-lang/setup-rust-toolchain@46268bd060767258de96ed93c1251119784f2ab6) to explicitly disable caching by adding cache: false under with:, e.g. add a cache: false entry alongside toolchain: ${{ env.RUST_TOOLCHAIN }} so the action will not enable its default cache behavior.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In @.github/workflows/seaweedfs.yml:
- Around line 153-167: The CI step that sets up Vault runs two apt installs
without automatic confirmation: the commands "sudo apt update && sudo apt
install gpg wget" and "sudo apt update && sudo apt install vault" should include
the noninteractive install flag (e.g., -y or -yqq) so they don't prompt and
hang; update those invocations in the "Setup vault" step to "sudo apt update &&
sudo apt install -y gpg wget" and "sudo apt update && sudo apt install -y vault"
(or use -yqq for quieter output) while keeping DEBIAN_FRONTEND=noninteractive.
---
Nitpick comments:
In @.github/workflows/seaweedfs.yml:
- Around line 119-125: The GitHub Actions step using
actions-rust-lang/setup-rust-toolchain currently uses default caching; to
mitigate cache-poisoning risk, update that step (the step referencing
actions-rust-lang/setup-rust-toolchain@46268bd060767258de96ed93c1251119784f2ab6)
to explicitly disable caching by adding cache: false under with:, e.g. add a
cache: false entry alongside toolchain: ${{ env.RUST_TOOLCHAIN }} so the action
will not enable its default cache behavior.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: d3693e95-108d-4be2-b90f-51ad3ca27e4a
📒 Files selected for processing (1)
.github/workflows/seaweedfs.yml
Replace floating latest/loosely-pinned tags with hashicorp/vault:1.21.4 (+ --cap-add IPC_LOCK required by recent images), openfga/openfga:v1.14, and chrislusf/seaweedfs:4.31 for reproducible runs.
Pin checkout (+ persist-credentials: false), azure/login, setup-rust-toolchain (with explicit toolchain), install-action, and nick-fields/retry to commit SHAs, matching the rest of the workflows.
The aws CLI requires a region even against an S3-compatible endpoint.
The AWS S3 tests read LAKEKEEPER_TEST__AWS_* env vars; the bare AWS_S3_* names (and secret names) were never picked up.
Pin upload-artifact, run on always() so results are captured on failure, and read from the selected NEXTEST_PROFILE dir (ci or ci_no_secrets).
The polling loop already waits for S3 readiness.
8b878de to
5426b8f
Compare
Add -yqq --no-install-recommends so the Setup vault step never waits on an install confirmation prompt, matching the Migrate database step's style.
@c-thiel That'll be great! Appreciate it! |
✅ PR Title Formatted CorrectlyThe title of this PR match the correct format. Thank you! |
This PR adds a new GitHub Actions workflow
seaweedfs.ymlthat runs unit tests against SeaweedFS. It builds SeaweedFS from source, starts it in mini mode with S3 enabled, creates a bucket, and runs the tests usingcargo nextest.Summary by CodeRabbit