This commit is contained in:
48
.gitea/workflows/smoke.yml
Normal file
48
.gitea/workflows/smoke.yml
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
name: smoke
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
smoke:
|
||||||
|
runs-on:
|
||||||
|
- debian-13
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Verify runner prerequisites
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
command -v bash >/dev/null
|
||||||
|
command -v curl >/dev/null
|
||||||
|
command -v gcc >/dev/null
|
||||||
|
command -v pkg-config >/dev/null
|
||||||
|
pkg-config --exists libnftables
|
||||||
|
|
||||||
|
- name: Install .NET SDK
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
curl -fsSL https://dot.net/v1/dotnet-install.sh -o dotnet-install.sh
|
||||||
|
bash dotnet-install.sh --channel 10.0 --quality ga --install-dir "$HOME/.dotnet"
|
||||||
|
|
||||||
|
- name: Show .NET info
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
"$HOME/.dotnet/dotnet" --info
|
||||||
|
|
||||||
|
- name: Restore
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
"$HOME/.dotnet/dotnet" restore
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
"$HOME/.dotnet/dotnet" build --no-restore
|
||||||
|
|
||||||
|
- name: Test
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
"$HOME/.dotnet/dotnet" test LibNftables.slnx --no-build
|
||||||
24
README.md
24
README.md
@@ -63,6 +63,30 @@ The test suite contains:
|
|||||||
- Native integration tests that self-gate when `libnftables` is unavailable
|
- Native integration tests that self-gate when `libnftables` is unavailable
|
||||||
- Capability-dependent tests that only run when `CAP_NET_ADMIN` is available
|
- Capability-dependent tests that only run when `CAP_NET_ADMIN` is available
|
||||||
|
|
||||||
|
## Gitea Smoke CI
|
||||||
|
|
||||||
|
The repository includes a Gitea Actions smoke workflow at `.gitea/workflows/smoke.yml`.
|
||||||
|
|
||||||
|
- Trigger: push and pull request
|
||||||
|
- Runner label: `debian-13`
|
||||||
|
- Job model: non-root smoke verification
|
||||||
|
- Workflow actions:
|
||||||
|
- bootstrap the .NET 10 SDK inside the job
|
||||||
|
- restore
|
||||||
|
- build
|
||||||
|
- run `dotnet test`
|
||||||
|
|
||||||
|
Important runner prerequisites:
|
||||||
|
|
||||||
|
- Debian 13 host with the `debian-13` label
|
||||||
|
- `bash`
|
||||||
|
- `curl`
|
||||||
|
- `gcc`
|
||||||
|
- `pkg-config`
|
||||||
|
- system-installed `libnftables` development/runtime packages discoverable by `pkg-config`
|
||||||
|
|
||||||
|
The job does not attempt package-manager installs or privilege escalation. It is intended to catch restore/build/test regressions, not to provide privileged nftables coverage.
|
||||||
|
|
||||||
## High-Level Example
|
## High-Level Example
|
||||||
|
|
||||||
```csharp
|
```csharp
|
||||||
|
|||||||
Reference in New Issue
Block a user