Skip to content

Commit

Permalink
Fix CI for dual kernel distros (#10)
Browse files Browse the repository at this point in the history
* stop using set-output
* default to arm64
* add distro to filename
* dont run slack job from forks or PRs
* Updated sbuild git module to 4e83148
  • Loading branch information
joshschmelzle authored Nov 30, 2024
1 parent d7ec438 commit daab6a7
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build-kernel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,21 +39,21 @@ jobs:
- name: Upload kernel
uses: actions/upload-artifact@v4
with:
name: wlanpi-kernel-${{ steps.build-kernel.outputs.package-version }}
name: wlanpi-kernel-${{ steps.build-kernel.outputs.package-version }}-${{ matrix.distro }}
path: ${{ steps.build-kernel.outputs.deb-package }}

- name: Upload package to debian/${{ matrix.distro }} on packagecloud
if: ${{ github.event.ref == format('refs/heads/{0}', github.event.repository.default_branch) }}
if: ${{ github.event.ref == format('refs/heads/{0}', github.event.repository.default_branch) && (github.repository_owner == 'WLAN-Pi') && (! github.event.pull_request.head.repo.fork) }}
uses: danielmundi/upload-packagecloud@main
with:
package-name: ${{ steps.build-kernel.outputs.deb-package }}
packagecloud-username: wlanpi
packagecloud-repo: dev
packagecloud-distrib: debian/${{ matrix.distro }}
packagecloud-token: ${{ secrets.PACKAGECLOUD_TOKEN }}

slack-workflow-status:
if: always()
if: ${{ always() && (github.repository_owner == 'WLAN-Pi') && (! github.event.pull_request.head.repo.fork) }}
name: Post Workflow Status to Slack
needs:
- build
Expand Down
6 changes: 4 additions & 2 deletions build-kernel.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ WLANPI_DEFCONFIG="wlanpi_v7l_defconfig"
KERNEL_FORCE_SYNC="0"
CLEAN_KERNEL="0"
SKIP_PATCHES="0"
DEB_ARCH="armhf"
DEB_ARCH="arm64"
EXEC_FUNC=""
NUM_CORES=$(($(nproc)/2))
export DEBFULLNAME="Daniel Finimundi"
Expand Down Expand Up @@ -227,7 +227,9 @@ prepare_build_package()
(cd debian; ./gen_kernel_preinst_postinst.sh "${KERNEL_ARCH// /,}")
dch -v "$DEBVER" -D bullseye --force-distribution "Kernel version ${KERNEL_VERSION}"

echo "::set-output name=package-version::${DEBVER}"
# https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
# echo "::set-output name=package-version::${DEBVER}"
echo "package-version=${DEBVER}" >> $GITHUB_OUTPUT
}

build_package()
Expand Down
2 changes: 1 addition & 1 deletion sbuild-debian-package
Submodule sbuild-debian-package updated 1 files
+5 −12 build.sh

0 comments on commit daab6a7

Please sign in to comment.