Onvif auth #319
Workflow file for this run
This file contains 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: Test webrtc thread leak | |
on: [push, pull_request] | |
jobs: | |
test-webrtc-thread-leak: | |
runs-on: ubuntu-22.04 | |
container: ubuntu:24.04 | |
env: | |
DEBIAN_FRONTEND: noninteractive | |
steps: | |
- name: Install build dependencies | |
run: | | |
apt update -y | |
apt install -y --no-install-recommends \ | |
libunwind-dev \ | |
libclang-dev \ | |
pkg-config \ | |
build-essential \ | |
curl \ | |
wget \ | |
gnupg \ | |
git \ | |
ca-certificates \ | |
libgit2-dev \ | |
libmount-dev \ | |
libsepol-dev \ | |
libselinux1-dev \ | |
libglib2.0-dev \ | |
libgudev-1.0-dev \ | |
libgstreamer1.0-dev \ | |
libgstreamer-plugins-base1.0-dev \ | |
libgstreamer-plugins-bad1.0-dev \ | |
libgstrtspserver-1.0-dev | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Install build dependencies - Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20' | |
- name: Set directory to safe for git | |
# Note: Required by vergen (https://crates.io/crates/vergen) | |
run: git config --global --add safe.directory $GITHUB_WORKSPACE | |
- name: Use cached dependencies | |
uses: Swatinem/rust-cache@v2 | |
with: | |
key: "${{ hashFiles('**/Cargo.lock') }}" | |
shared-key: "shared" | |
- name: Install build dependencies - Rustup/unzip | |
run: | | |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain stable -y | |
echo "$HOME/.cargo/bin" >> $GITHUB_PATH | |
apt-get install -y unzip | |
- uses: oven-sh/setup-bun@v2 | |
with: | |
bun-version: latest | |
- name: Build | |
run: cargo build --verbose --locked | |
- name: Install runtime dependencies | |
run: | | |
apt update -y | |
apt install -y --no-install-recommends \ | |
gstreamer1.0-tools \ | |
gstreamer1.0-x \ | |
gstreamer1.0-nice \ | |
gstreamer1.0-libav \ | |
gstreamer1.0-plugins-ugly | |
- name: Install runtime dependencies - Google Chrome and Chromedriver | |
# Get the json API from https://github.com/GoogleChromeLabs/chrome-for-testing?tab=readme-ov-file#json-api-endpoints | |
run: | | |
apt install -y --no-install-recommends jq unzip | |
wget --no-check-certificate https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions-with-downloads.json -O /tmp/downloads.json | |
mkdir -p /opt/google | |
chrome_url=$(jq -r '."channels"."Stable"."downloads"."chrome"[] | select(."platform" == "linux64") | ."url"' /tmp/downloads.json) | |
wget --no-check-certificate $chrome_url -O /tmp/chrome.zip | |
unzip /tmp/chrome.zip -d /tmp/ | |
mv -f /tmp/chrome-linux64 /opt/google/chrome | |
ln -s /opt/google/chrome/chrome /usr/bin/chrome | |
chromedriver_url=$(jq -r '."channels"."Stable"."downloads"."chromedriver"[] | select(."platform" == "linux64") | ."url"' /tmp/downloads.json) | |
wget --no-check-certificate $chromedriver_url -O /tmp/chromedriver.zip | |
unzip /tmp/chromedriver.zip -d /tmp/ | |
mv -f /tmp/chromedriver-linux64 /opt/google/chromedriver | |
ln -s /opt/google/chromedriver/chromedriver /usr/bin/chromedriver | |
- name: Run test | |
run: | | |
RUST_BACKTRACE=1 timeout 300 cargo run --verbose -- \ | |
--mavlink udpin:0.0.0.0:6666 --verbose --default-settings WebRTCTest --enable-webrtc-task-test 6666 |