-
Notifications
You must be signed in to change notification settings - Fork 4
61 lines (53 loc) · 1.76 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Build Bazzite Kernel
on:
workflow_dispatch:
release:
types: [published]
permissions:
contents: write
jobs:
build_kernel:
runs-on: ubuntu-24.04
environment: prod
strategy:
fail-fast: false
matrix:
arch: [x86_64]
fedora_version: [40]
steps:
# - name: Maximize build space
# uses: ublue-os/remove-unwanted-software@v7
- name: Checkout repository
uses: actions/checkout@v4
- name: Create Build Environment
run: |
sudo podman build . --tag 'fedora_builder' --build-arg UID=$(id -u) --build-arg GID=$(id -g)
- name: Compile Kernel
run: |
sudo podman run --rm -v $(pwd):/workspace fedora_builder fedpkg \
--name kernel --namespace rpms --release "f${{ matrix.fedora_version }}" \
local --arch "${{ matrix.arch }}" --with baseonly \
--builddir build --buildrootdir buildroot
- name: Upload Kernel to action
uses: actions/upload-artifact@v4
with:
name: kernel-f${{ matrix.fedora_version}}-${{ matrix.arch }}
path: |
.build-*.log
${{ matrix.arch }}/kernel-*.rpm
compression-level: 0 # already compressed
- name: Upload Kernel to release
if: github.event_name == 'release'
uses: softprops/action-gh-release@v2
with:
files: |
.build-*.log
${{ matrix.arch }}/kernel-*.rpm
tag_name: ${{ github.ref_name }}
body: |
Fill me in. Workflow ran manually (?).
draft: true
# if we did not run on a release, it is a pre-release
prerelease: true # contains(github.ref, 'pre')
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}