Skip to content

chore: Add Linux ARM tests to CI #27

chore: Add Linux ARM tests to CI

chore: Add Linux ARM tests to CI #27

Workflow file for this run

name: test
on:
workflow_dispatch:
pull_request:
push:
branches:
- 'main'
jobs:
test-linux:
strategy:
max-parallel: 4
matrix:
runs-on: [ubuntu-latest, ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, ubuntu-24.04-arm, ubuntu-22.04-arm]
include:
- runs-on: ubuntu-latest
service-key: SERVICE_KEY
- runs-on: ubuntu-24.04
service-key: SERVICE_KEY1
- runs-on: ubuntu-22.04
service-key: SERVICE_KEY2
- runs-on: ubuntu-20.04
service-key: SERVICE_KEY3
- runs-on: ubuntu-24.04-arm
service-key: SERVICE_KEY_ARM1
- runs-on: ubuntu-22.04-arm
service-key: SERVICE_KEY_ARM2
runs-on: ${{ matrix.runs-on }}
steps:
- uses: actions/checkout@v4
- name: Move local action to folder where it can be tested
shell: bash
run: |
mkdir -p .github/actions/test
cp action.yml .github/actions/test/action.yml
- uses: ./.github/actions/test
with:
service-key: ${{ secrets[matrix.service-key] }}
- name: (optional) Twingate logs
run: journalctl -u twingate
- name: (optional) Twingate status
run: twingate status
- name: Access a secure resource
env:
TEST_URL: http://business.prod.beamreachinc.int/
run: |
echo Calling $TEST_URL 🚀
curl -v $TEST_URL
- name: Print client logs
if: always()
run: journalctl -u twingate
- run: echo "SUCCESS!!! 🤩 This job's status is ${{ job.status }}."
test-windows:
strategy:
max-parallel: 4
matrix:
runs-on: [windows-latest, windows-2025, windows-2022, windows-2019]
include:
- runs-on: windows-latest
service-key: SERVICE_KEY_WIN1
- runs-on: windows-2025
service-key: SERVICE_KEY_WIN2
- runs-on: windows-2022
service-key: SERVICE_KEY_WIN3
- runs-on: windows-2019
service-key: SERVICE_KEY_WIN4
runs-on: ${{ matrix.runs-on }}
steps:
- uses: actions/checkout@v4
- name: Move local action to folder where it can be tested
shell: powershell
run: |
New-Item -Path ".github/actions/test" -ItemType Directory -Force
Copy-Item -Path "action.yml" -Destination ".github/actions/test/action.yml" -Force
- uses: ./.github/actions/test
with:
service-key: ${{ secrets[matrix.service-key] }}
- name: Access a secure resource
shell: powershell
env:
TEST_URL: http://business.prod.beamreachinc.int/
run: |
Write-Host "Calling $env:TEST_URL 🚀"
Invoke-WebRequest -Uri $env:TEST_URL -Verbose
- name: Print client logs
shell: powershell
if: always()
run: Get-Content "$env:PROGRAMDATA\Twingate\logs\twingate.service.log"
- shell: powershell
run: Write-Host "SUCCESS!!! 🤩 This job's status is ${{ job.status }}."