Skip to content

Commit

Permalink
feat: enable fedora 39 builds (ublue-os#301)
Browse files Browse the repository at this point in the history
Co-authored-by: RJ Trujillo <eyecantcu@pm.me>
  • Loading branch information
p5 and EyeCantCU authored Sep 19, 2023
1 parent 9d853a1 commit 67d4669
Show file tree
Hide file tree
Showing 5 changed files with 66 additions and 21 deletions.
18 changes: 16 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,29 +21,37 @@ jobs:
matrix:
image_flavor: [main, nvidia]
image_name: [silverblue, kinoite, vauxite, sericea, base, lxqt, mate]
major_version: [37, 38]
major_version: [37, 38, 39]
nvidia_version: [0, 470, 535]
include:
- major_version: 37
is_latest_version: false
is_stable_version: true
is_gts_version: false
- major_version: 38
is_latest_version: true
is_stable_version: true
is_gts_version: true
- major_version: 39
is_latest_version: true
is_stable_version: false
is_gts_version: false
- nvidia_version: 535
is_latest_nvidia: true
exclude:
# There is no Fedora 37 version of sericea
# When F38 is added, sericea will automatically be built too
- image_name: sericea
major_version: 37
- image_name: vauxite
major_version: 39
- image_flavor: main
nvidia_version: 470
- image_flavor: main
nvidia_version: 535
- image_flavor: nvidia
nvidia_version: 0
steps:
steps:
# Checkout push-to-registry action GitHub repository
- name: Checkout Push to Registry action
uses: actions/checkout@v4
Expand Down Expand Up @@ -103,6 +111,12 @@ jobs:
BUILD_TAGS+=("${TIMESTAMP}")
BUILD_TAGS+=("latest")
fi
elif [[ "${{ matrix.is_gts_version }}" == "true" ]]; then
if [[ "${{ matrix.image_flavor }}" == "main" ]] || \
[[ "${{ matrix.is_latest_nvidia }}" == "true" ]]; then
BUILD_TAGS+=("gts-${TIMESTAMP}")
BUILD_TAGS+=("gts")
fi
fi
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
Expand Down
6 changes: 3 additions & 3 deletions Containerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
ARG IMAGE_NAME="${IMAGE_NAME:-silverblue}"
ARG SOURCE_IMAGE="${SOURCE_IMAGE:-silverblue}"
ARG BASE_IMAGE="quay.io/fedora-ostree-desktops/${SOURCE_IMAGE}"
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION:-38}"
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION:-39}"


FROM ${BASE_IMAGE}:${FEDORA_MAJOR_VERSION} AS main
ARG IMAGE_NAME="${IMAGE_NAME:-silverblue}"
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION:-38}"
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION:-39}"

COPY github-release-install.sh /tmp/github-release-install.sh
COPY main-install.sh /tmp/main-install.sh
Expand All @@ -29,7 +29,7 @@ RUN mkdir -p /var/tmp && chmod -R 1777 /var/tmp

FROM main AS nvidia
ARG IMAGE_NAME="${IMAGE_NAME:-silverblue}"
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION:-38}"
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION:-39}"
ARG NVIDIA_MAJOR_VERSION="${NVIDIA_MAJOR_VERSION:-535}"

COPY nvidia-install.sh /tmp/nvidia-install.sh
Expand Down
15 changes: 9 additions & 6 deletions main-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,15 @@ for REPO in $(rpm -ql ublue-os-akmods-addons|grep ^"/etc"|grep repo$); do
sed -i '0,/enabled=0/{s/enabled=0/enabled=1/}' ${REPO}
done

rpm-ostree install \
/tmp/akmods-rpms/kmods/*openrazer*.rpm \
/tmp/akmods-rpms/kmods/*v4l2loopback*.rpm \
/tmp/akmods-rpms/kmods/*xpadneo*.rpm \
/tmp/akmods-rpms/kmods/*xone*.rpm \
/tmp/akmods-rpms/kmods/*xpad-noone*.rpm
# Only run if FEDORA_MAJOR_VERSION is not 39
if grep -qv "39" <<< $FEDORA_MAJOR_VERSION; then
rpm-ostree install \
/tmp/akmods-rpms/kmods/*xpadneo*.rpm \
/tmp/akmods-rpms/kmods/*xpad-noone*.rpm \
/tmp/akmods-rpms/kmods/*xone*.rpm \
/tmp/akmods-rpms/kmods/*openrazer*.rpm \
/tmp/akmods-rpms/kmods/*v4l2loopback*.rpm
fi

for REPO in $(rpm -ql ublue-os-akmods-addons|grep ^"/etc"|grep repo$); do
echo "akmods: disable per defaults: ${REPO}"
Expand Down
42 changes: 33 additions & 9 deletions main-packages.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"google-noto-sans-javanese-fonts",
"google-noto-sans-balinese-fonts",
"google-noto-sans-sundanese-fonts",
"google-noto-sans-cjk-fonts",
"nvme-cli",
"nvtop",
"openrgb-udev-rules",
Expand All @@ -45,8 +44,7 @@
],
"silverblue": [
"adw-gtk3-theme",
"gnome-tweaks",
"raw-thumbnailer"
"gnome-tweaks"
],
"kinoite": [
"icoutils",
Expand Down Expand Up @@ -175,7 +173,6 @@
"pipewire-alsa",
"pipewire-pulseaudio",
"pluma",
"raw-thumbnailer",
"seahorse",
"seahorse-caja",
"setroubleshoot",
Expand All @@ -193,7 +190,6 @@
"clipman"
],
"vauxite": [
"raw-thumbnailer",
"xfce4-clipman-plugin",
"xfce4-whiskermenu-plugin"
]
Expand Down Expand Up @@ -224,12 +220,21 @@
},
"37": {
"include": {
"all": [],
"all": [
"google-noto-sans-cjk-fonts"
],
"silverblue": [
"raw-thumbnailer"
],
"mate": [
"f37-backgrounds-base",
"f37-backgrounds-extras-base",
"f37-backgrounds-extras-mate",
"f37-backgrounds-mate"
"f37-backgrounds-mate",
"raw-thumbnailer"
],
"vauxite": [
"raw-thumbnailer"
]
},
"exclude": {
Expand All @@ -238,16 +243,35 @@
},
"38": {
"include": {
"all": [],
"all": [
"google-noto-sans-cjk-fonts"
],
"silverblue": [
"raw-thumbnailer"
],
"mate": [
"f38-backgrounds-base",
"f38-backgrounds-extras-base",
"f38-backgrounds-extras-mate",
"f38-backgrounds-mate"
"f38-backgrounds-mate",
"raw-thumbnailer"
],
"vauxite": [
"raw-thumbnailer"
]
},
"exclude": {
"all": []
}
},
"39": {
"include": {
"all": []
},
"exclude": {
"all": [
"default-fonts-cjk-sans"
]
}
}
}
6 changes: 5 additions & 1 deletion nvidia-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@

set -ouex pipefail

sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/fedora-{cisco-openh264,modular,updates-modular}.repo
if [[ "${FEDORA_MAJOR_VERSION}" -le 38 ]]; then
sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/fedora-{cisco-openh264,modular,updates-modular}.repo
else
sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/fedora-cisco-openh264.repo
fi

rpm-ostree install \
/tmp/akmods-rpms/ublue-os/ublue-os-nvidia-addons-*.rpm
Expand Down

0 comments on commit 67d4669

Please sign in to comment.