mirror of
https://github.com/chatmail/relay.git
synced 2026-09-14 19:33:14 +00:00
ci: build and deploy relays with filtermail binary and run interop tests against madmail (#131)
* ci: Run relay integration tests using cmlxc Builds filtermail and runs cmlxc tests against a patched chatmail/relay. Signed-off-by: Jagoda Ślązak <jslazak@jslazak.com> * ci: run integration tests with branch filtermail binary deployed with chatmail/relay main code --------- Signed-off-by: Jagoda Ślązak <jslazak@jslazak.com> Co-authored-by: Jagoda Ślązak <jslazak@jslazak.com>
This commit is contained in:
co-authored by
Jagoda Ślązak
parent
a30c8b3995
commit
3ee0bfd35b
Vendored
+30
-2
@@ -11,6 +11,10 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
fmt:
|
fmt:
|
||||||
name: Check Formatting
|
name: Check Formatting
|
||||||
@@ -59,8 +63,8 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
RUSTUP_TOOLCHAIN: ${{ matrix.toolchain }}
|
RUSTUP_TOOLCHAIN: ${{ matrix.toolchain }}
|
||||||
|
|
||||||
test:
|
rust-test:
|
||||||
name: Test on ${{ matrix.os }}
|
name: Run rust tests on ${{ matrix.os }}
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
@@ -75,3 +79,27 @@ jobs:
|
|||||||
toolchain: stable
|
toolchain: stable
|
||||||
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2
|
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2
|
||||||
- run: cargo test
|
- run: cargo test
|
||||||
|
|
||||||
|
relay-test:
|
||||||
|
name: Test the relay with cmlxc and custom filtermail
|
||||||
|
uses: chatmail/cmlxc/.github/workflows/lxc-test.yml@main
|
||||||
|
with:
|
||||||
|
cmlxc_commands: |
|
||||||
|
sudo apt-get update && sudo apt-get install -y musl-tools
|
||||||
|
rustup target add x86_64-unknown-linux-musl
|
||||||
|
export CARGO_TARGET_X86_64_UNKNOWN_LINUX_MUSL_LINKER=musl-gcc
|
||||||
|
cd repo && RUSTFLAGS="-Ctarget-feature=+crt-static -Clink-self-contained=yes" cargo build --release --target x86_64-unknown-linux-musl
|
||||||
|
cmlxc init
|
||||||
|
cmlxc -v deploy-cmdeploy --filtermail repo/target/x86_64-unknown-linux-musl/release/filtermail cm0
|
||||||
|
cmlxc -v test-mini cm0
|
||||||
|
cmlxc -v test-cmdeploy cm0
|
||||||
|
|
||||||
|
# cross cmdeploy relay test
|
||||||
|
cmlxc -v deploy-cmdeploy --filtermail repo/target/x86_64-unknown-linux-musl/release/filtermail --ipv4-only cm1
|
||||||
|
cmlxc -v test-cmdeploy cm0 cm1
|
||||||
|
|
||||||
|
# cross cmdeploy/madmail relay tests
|
||||||
|
cmlxc -v deploy-madmail mad0
|
||||||
|
cmlxc -v test-cmdeploy cm0 mad0
|
||||||
|
cmlxc -v test-mini cm0 mad0
|
||||||
|
cmlxc -v test-mini mad0 cm0
|
||||||
|
|||||||
Reference in New Issue
Block a user