aurora/build_scripts/shared/build-prep.sh
renner b2d6f3cfb3
refactor: simplify checking for enabled 3rd party repos (#2931)
* refactor: simplify checking for enabled 3rd party repos

We are generally no longer doing the dnf enable/disable dance (except
for the nvidia install script) because we are vendoring the .repo files
which simplifies things a bit.

Also I think that the move to checking what is allowed instead of
checking what is not allowed makes more sense anyway.

resolves: https://github.com/ublue-os/aurora/issues/2854

[1] 1e4d10b9ac/build_files/nvidia/nvidia-install.sh

* get openh264 from negativo

Our base image [1] can't legally include this from fedora-cisco-openh264
repo. Comparing the spec files for Fedora [2] and Negativo [3], they
seem to be built with the same build flags, so they should not have any
differing functionality. The fedora-cisco-openh264 repo is currently
enabled (which is not the case for F44 images) because our repo
validation script broke due to the move to /usr [4].

We are already shipping various other codecs on the system, including
mesa, they get more irrelevant each day but we should have this.

I don't know why exactly but for some reason we now have a stray
/var/log/dnf5.log which makes bootc container lint fail.

[1] 54e811f17a/common.yaml (L144)
[2] cd15228484/f/openh264.spec
[3] dfac89f533/openh264.spec
[4] https://fedoraproject.org/wiki/Changes/RelocateRpmRepoConfigsToUsr
2026-09-27 05:34:43 +00:00

32 lines
906 B
Bash
Executable file

# This script should generally set up the build so we can move on to start installing packages
#!/usr/bin/bash
set -eoux pipefail
# Speeds up local builds and workaround network flakes, mainly for COPR and negativo
cp /etc/dnf/dnf.conf /etc/dnf/dnf.conf.bak
dnf config-manager setopt keepcache=1 timeout=60
# configuring dnf repos
BUILD_FILES=(
"/ctx/build_files/shared/"
)
if [[ "${IMAGE_FLAVOR}" == "dx" ]]; then
BUILD_FILES+=("/ctx/build_files/dx/")
fi
rsync -rvKl "${BUILD_FILES[@]}" /
# mostly for codecs fedora can't ship
dnf config-manager setopt fedora-multimedia.priority=90
# https://fedoraproject.org/wiki/OpenH264
# this would be fine to use as well, negativo just has it, one less repo
dnf config-manager setopt fedora-cisco-openh264.enabled=0
mkdir -p /tmp/scripts/helpers
install -Dm0755 /ctx/build_scripts/shared/utils/ghcurl /tmp/scripts/helpers/ghcurl
echo "::endgroup::"