mirror of
https://github.com/Quad4-Software/Reticulum-Go
synced 2026-08-29 23:48:44 -04:00
63 lines
1.8 KiB
YAML
63 lines
1.8 KiB
YAML
# Host self-check on Android emulator (manual / nightly).
|
|
# Does not block PR CI until the job is stable.
|
|
name: Self-check Android
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
schedule:
|
|
- cron: "30 5 * * 1"
|
|
|
|
concurrency:
|
|
group: selfcheck-android-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
env:
|
|
CI_GO_VERSION: "1.26.6"
|
|
GOFLAGS: -mod=vendor
|
|
GOPROXY: "off"
|
|
GOTOOLCHAIN: local
|
|
|
|
jobs:
|
|
selfcheck-android:
|
|
name: Android emulator self-check
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 90
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
|
|
|
- name: Setup Go
|
|
uses: actions/setup-go@40f1582b2485089dde7abd97c1529aa768e1baff # v5.6.0
|
|
with:
|
|
go-version: ${{ env.CI_GO_VERSION }}
|
|
check-latest: false
|
|
cache: false
|
|
|
|
- name: Enable KVM
|
|
run: |
|
|
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
|
|
sudo udevadm control --reload-rules
|
|
sudo udevadm trigger --name-match=kvm
|
|
|
|
- name: Build android arm64 self-check binary
|
|
env:
|
|
CGO_ENABLED: "0"
|
|
GOOS: android
|
|
GOARCH: arm64
|
|
run: |
|
|
mkdir -p bin/android/arm64
|
|
go build -ldflags="-s -w" -o bin/android/arm64/reticulum-go ./cmd/reticulum-go
|
|
|
|
- name: Run emulator and self-check
|
|
uses: reactivecircus/android-emulator-runner@1dcd0090116d15e7c562f8db72807de5e036a4ed # v2.34.0
|
|
with:
|
|
api-level: 30
|
|
arch: arm64-v8a
|
|
target: default
|
|
force-avd-creation: false
|
|
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
|
|
disable-animations: true
|
|
script: sh scripts/ci/run-android-self-check.sh
|