Some checks failed
Lint and Build / build (pull_request) Failing after 27s
- Add automatic detection and installation of build-essential - Support Ubuntu/Debian, Alpine, and RHEL/CentOS ARM runners - Resolves 'c++: No such file or directory' error for native modules - Ensures bufferutil and other native dependencies can compile 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
50 lines
No EOL
1.2 KiB
YAML
50 lines
No EOL
1.2 KiB
YAML
name: Lint and Build
|
|
|
|
on:
|
|
push:
|
|
branches: [ main ]
|
|
pull_request:
|
|
branches: [ main ]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: self-hosted
|
|
# Note: Node.js is pre-installed on self-hosted runners
|
|
|
|
steps:
|
|
- name: Checkout Repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install build dependencies
|
|
run: |
|
|
if command -v apt-get >/dev/null 2>&1; then
|
|
sudo apt-get update
|
|
sudo apt-get install -y build-essential python3-dev
|
|
elif command -v apk >/dev/null 2>&1; then
|
|
sudo apk add --no-cache build-base python3-dev
|
|
elif command -v yum >/dev/null 2>&1; then
|
|
sudo yum groupinstall -y "Development Tools"
|
|
sudo yum install -y python3-devel
|
|
fi
|
|
|
|
- name: Clean NextJS cache
|
|
run: rm -rf .next
|
|
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
|
|
- name: Run type check
|
|
run: npm run type-check
|
|
|
|
- name: Run linter
|
|
run: npm run lint
|
|
|
|
- name: Build project
|
|
run: npm run build
|
|
|
|
- name: Upload Build Artifact
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: obs-ss-build
|
|
include-hidden-files: 'true'
|
|
path: ./.next/* |