Skip to content

Update runner

Update runner #28

Workflow file for this run

name: Run on .config or kernel-url Change
on:
push:
paths:
- "runner"
jobs:
process-config:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Log Change
run: |
echo "runner has been modified. Processing changes..."
- name: Install wget and dependencies
run: |
sudo apt-get update
sudo apt-get install -y wget tar libncurses-dev bison flex libssl-dev libelf-dev bc zstd unzip rsync
# Cache the 'kext' directory to avoid re-downloading kernel on each run
- name: Cache kernel source
uses: actions/[email protected]
with:
path: kext/
key: ${{ runner.os }}-kext-${{ hashFiles('kernel-url') }}
restore-keys: |
${{ runner.os }}-kext-
enableCrossOsArchive: false
fail-on-cache-miss: false
lookup-only: false
save-always: false
if: steps.cache-check.outcome == 'success'
# Download, extract, and build kernel, always running make
- name: Download, extract, and build kernel
run: |
# Download the kernel source only if it's not cached
if [ ! -d "kext" ]; then
wget -q -i kernel-url -O kernel.tar.xz
mkdir -p kext
tar -xf kernel.tar.xz -C kext --strip-components=1
fi
# Copy the .config file and update configuration
rsync -av .config kext/
rsync -av fw kext/
cd kext
# Run make every time, even if cached
make -j$(nproc) olddefconfig
- name: Set dynamic tag version
run: |
# Generate a dynamic tag using commit SHA or other unique identifier
VERSION="v$(date +'%Y%m%d%H%M%S')" # Format: vYYYYMMDDHHMMSS>
echo "VERSION=${VERSION}" >> $GITHUB_ENV
- name: Create a new GitHub release and tag
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ env.VERSION }}
name: "Release ${{ env.VERSION }}"
body: "This release includes the latest build for Debian rootfs."
files: |
kext/arch/x86/boot/bzImage
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}