Skip to content

Commit

Permalink
ci: Use vmactions/freebsd-vm
Browse files Browse the repository at this point in the history
  • Loading branch information
tavianator committed Jan 2, 2024
1 parent 1117564 commit 94b955b
Showing 1 changed file with 19 additions and 16 deletions.
35 changes: 19 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,25 +62,28 @@ jobs:
freebsd:
name: FreeBSD

if: ${{ github.repository_owner == 'tavianator' && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) }}

runs-on: ubuntu-22.04

concurrency: spurion

steps:
- uses: actions/checkout@v4

- uses: tailscale/github-action@v2
with:
oauth-client-id: ${{ secrets.TS_OAUTH_CLIENT_ID }}
oauth-secret: ${{ secrets.TS_OAUTH_SECRET }}
tags: tag:ci

- name: Run tests
run: |
spurion=$(tailscale ip -6 spurion)
mkdir ~/.ssh
printf 'Host %s\n\tStrictHostKeyChecking=accept-new\n\tUser github\n' "$spurion" >~/.ssh/config
rsync -rl --delete . "[$spurion]:bfs"
ssh "$spurion" '. ~/.ssh/rc; gmake -C bfs -j$(nproc) distcheck CC=clang16 JOBS=-j$(nproc)'
uses: vmactions/freebsd-vm@v1
with:
usesh: true

prepare: |
pkg install -y \
bash \
expect \
gmake \
llvm16 \
oniguruma \
sudo \
tcl-wrapper
pw useradd -n action -m -G wheel -s /usr/local/bin/bash
echo "%wheel ALL=(ALL) NOPASSWD: ALL" >>/usr/local/etc/sudoers
run: |
chown -R action:action .
su action -c 'gmake -j$(nproc) distcheck CC=clang16 JOBS=-j$(nproc)'

0 comments on commit 94b955b

Please sign in to comment.