auto-update to linux-6.12.8.tar.xz #58
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test Boot | |
on: | |
pull_request: | |
branches: [ main ] | |
jobs: | |
build: | |
name: CI | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up Go 1.x | |
uses: actions/setup-go@v2 | |
with: | |
# Run on the latest minor release of Go 1.22: | |
go-version: ^1.22 | |
id: go | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v2 | |
- name: Ensure all files were formatted as per gofmt | |
run: | | |
[ "$(gofmt -l $(find . -name '*.go') 2>&1)" = "" ] | |
- name: Install dependencies | |
run: | | |
sudo apt update && sudo apt install qemu-system-arm qemu-efi-aarch64 | |
GOPROXY=direct go install github.com/gokrazy/autoupdate/cmd/...@latest | |
GOPROXY=direct GOBIN=$PWD/_build go install github.com/gokrazy/autoupdate/cmd/gokr-rebuild-kernel@latest | |
GOPROXY=direct go install github.com/gokrazy/tools/cmd/gok@latest | |
GOPROXY=direct go install github.com/gokrazy/bakery/cmd/qemubootery@latest | |
# TODO: once https://github.com/actions/runner/issues/662 is fixed, we can | |
# remove the gokr-has-label guards and terminate a CI run instead. | |
- name: Test Boot on qemu | |
env: | |
GITHUB_REPOSITORY: ${{ secrets.GITHUB_REPOSITORY }} | |
GH_USER: ${{ secrets.GH_USER }} | |
GH_AUTH_TOKEN: ${{ secrets.GH_AUTH_TOKEN }} | |
TRAVIS_PULL_REQUEST: ${{ github.event.pull_request.number }} | |
TRAVIS_PULL_REQUEST_BRANCH: ${{ github.event.pull_request.head.ref }} | |
BOOTERY_URL: ${{ secrets.BOOTERY_URL }} | |
GOKRAZY_BAKERY_PASSWORD: ${{ secrets.GOKRAZY_BAKERY_PASSWORD }} | |
if: ${{ env.GH_USER != 0 }} | |
run: | | |
.github/workflows/create-bakery.bash | |
gok -i bakery add . | |
sed -i 's,"Hostname": "[^"]*","Hostname": "qemubakery",g' ~/gokrazy/bakery/config.json | |
if gokr-has-label please-boot-qemu; then cd ~/gokrazy/bakery && { truncate -s 64m varstore.img && truncate -s 64m efi.img && dd if=/usr/share/qemu-efi-aarch64/QEMU_EFI.fd of=efi.img conv=notrunc && qemubootery -arch=arm64 & GOARCH=arm64 gokr-boot -require_label=please-boot-qemu -set_label=please-merge -bootery_url=http://localhost:8037/testboot; }; fi | |
- name: Build Linux kernel and amend Pull Request | |
env: | |
GITHUB_REPOSITORY: ${{ secrets.GITHUB_REPOSITORY }} | |
GH_USER: ${{ secrets.GH_USER }} | |
GH_AUTH_TOKEN: ${{ secrets.GH_AUTH_TOKEN }} | |
TRAVIS_PULL_REQUEST: ${{ github.event.pull_request.number }} | |
TRAVIS_PULL_REQUEST_BRANCH: ${{ github.event.pull_request.head.ref }} | |
BOOTERY_URL: ${{ secrets.BOOTERY_URL }} | |
if: ${{ env.GH_USER != 0 }} | |
run: | | |
if ! gokr-has-label please-merge && ! gokr-has-label please-boot-qemu; then (cd _build && ./gokr-rebuild-kernel -cross=arm64 -dtbs= -overwrite_container_executable=docker) && gokr-amend -set_label=please-boot-qemu lib vmlinuz; fi | |
- name: Merge if boot successful | |
env: | |
GITHUB_REPOSITORY: ${{ secrets.GITHUB_REPOSITORY }} | |
GH_USER: ${{ secrets.GH_USER }} | |
GH_AUTH_TOKEN: ${{ secrets.GH_AUTH_TOKEN }} | |
TRAVIS_PULL_REQUEST: ${{ github.event.pull_request.number }} | |
TRAVIS_PULL_REQUEST_BRANCH: ${{ github.event.pull_request.head.ref }} | |
BOOTERY_URL: ${{ secrets.BOOTERY_URL }} | |
run: | | |
if gokr-has-label please-merge; then set +e; gokr-merge -require_label=please-merge; ret=$?; [ $ret -eq 2 ] || exit $ret; fi | |