Feature/vpn 4192 fix domain fronting #3175
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci-nym-vpn-core-linux | |
on: | |
pull_request: | |
types: [opened, synchronize, reopened] | |
paths: | |
- "nym-vpn-core/crates/**" | |
- "nym-vpn-core/Cargo.toml" | |
- ".github/workflows/ci-nym-vpn-core-linux.yml" | |
workflow_dispatch: | |
env: | |
CARGO_TERM_COLOR: always | |
AGENT_ISSELFHOSTED: 1 # https://github.com/actions/setup-go/issues/432 | |
jobs: | |
build-wireguard-go-linux: | |
uses: ./.github/workflows/build-wireguard-go-linux.yml | |
build: | |
if: github.actor != 'dependabot[bot]' | |
runs-on: arc-linux-latest | |
needs: build-wireguard-go-linux | |
steps: | |
- name: Install system dependencies | |
run: sudo apt-get update && sudo apt-get install -y libdbus-1-dev libmnl-dev libnftnl-dev protobuf-compiler git curl gcc g++ make unzip | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
- name: Install rust toolchain | |
uses: dtolnay/rust-toolchain@master | |
with: | |
toolchain: ${{ vars.REQUIRED_RUSTC_VERSION }} | |
components: rustfmt, clippy | |
- name: Install Protoc | |
uses: arduino/setup-protoc@v3 | |
with: | |
version: "21.12" # 3.21.12: the version on ubuntu 24.04. Don't change this! | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Cache Cargo registry | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/bin/ | |
~/.cargo/registry/index/ | |
~/.cargo/registry/cache/ | |
~/.cargo/git/db/ | |
key: ${{ runner.os }}-cargo-${{ hashFiles('nym-vpn-core/Cargo.lock') }} | |
restore-keys: | | |
${{ runner.os }}-cargo- | |
- name: Cache Cargo build | |
uses: actions/cache@v4 | |
with: | |
path: nym-vpn-core/target/ | |
key: ${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}-${{ hashFiles('nym-vpn-core/**/*.rs') }} | |
restore-keys: | | |
${{ runner.os }}-cargo-build-${{ hashFiles('nym-vpn-core/Cargo.lock') }}- | |
${{ runner.os }}-cargo-build- | |
# To avoid running out of disk space, skip generating debug symbols | |
- name: Set debug to false | |
working-directory: nym-vpn-core | |
run: | | |
sed -i.bak '1s/^/\[profile.dev\]\ndebug = false\n\n/' Cargo.toml | |
git diff | |
- name: Download artifacts | |
uses: actions/download-artifact@v5 | |
with: | |
name: wireguard-go_ubuntu-24.04_x86_64 | |
path: build/lib/x86_64-unknown-linux-gnu | |
- name: rustfmt check | |
working-directory: nym-vpn-core | |
run: | | |
cargo fmt --check --all | |
- name: Clippy | |
working-directory: nym-vpn-core | |
run: | | |
cargo clippy --workspace --locked -- -Dwarnings | |
- name: Build | |
working-directory: nym-vpn-core | |
run: | | |
cargo build --verbose --workspace --locked | |
- name: Run tests | |
working-directory: nym-vpn-core | |
run: | | |
cargo test --verbose --workspace --locked |