Spaces:
Paused

NouGenShards / .github /workflows /linux-setup.yml
github-actions[bot]
Space deploy: snapshot of 0334965acf53e20adff5bb72841a38b7e28f0d4a
79a311c
Raw History Blame Contribute Delete
1.92 kB
name: linux-setup
# Runs the Join setup script tests (the real generated setup.sh against
# stand-ins for the network) on Ubuntu, Debian, and a container with no
# systemd and no cron. Free GitHub-hosted runners only.
on:
push:
branches: [main]
paths: ["workers/join/**", "tests/js/**", "tools/nougen-supervisor/**", ".github/workflows/linux-setup.yml"]
pull_request:
paths: ["workers/join/**", "tests/js/**", "tools/nougen-supervisor/**", ".github/workflows/linux-setup.yml"]
permissions:
contents: read
jobs:
ubuntu:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7.1.0
with:
node-version: "22"
- name: Join and setup.sh tests
run: node --test --test-reporter=spec tests/js/*.test.mjs
containers:
strategy:
fail-fast: false
matrix:
include:
- name: debian
image: node:22-bookworm-slim
- name: no-systemd-sandbox
image: node:22-alpine
name: ${{ matrix.name }}
runs-on: ubuntu-latest
container:
image: ${{ matrix.image }}
env:
# Neither image has systemd, so setup must pick foreground mode by itself.
NOUGEN_EXPECT_SANDBOX: "1"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
# No systemd here. Alpine's busybox still ships a crontab binary, which
# setup must ignore inside a container: nothing runs it after a restart.
- name: No systemd
run: |
if command -v systemctl; then echo "expected a box with no systemd"; exit 1; fi
- name: Join and setup.sh tests
run: node --test --test-reporter=spec tests/js/*.test.mjs