feat: install repos first, so that they're available for scripting
This ensures that custom scripts have the flexibility to work with the repos that have been added.
This commit is contained in:
20
build.sh
20
build.sh
@@ -3,6 +3,16 @@
|
|||||||
# Tell build process to exit if there are any errors.
|
# Tell build process to exit if there are any errors.
|
||||||
set -ouex pipefail
|
set -ouex pipefail
|
||||||
|
|
||||||
|
# Add custom repos.
|
||||||
|
repos=$(yq '.extrarepos[]' < /usr/etc/ublue-recipe.yml)
|
||||||
|
if [[ -n "$repos" ]]; then
|
||||||
|
echo "-- Adding repos defined in recipe.yml --"
|
||||||
|
for repo in $(echo -e "$repos"); do \
|
||||||
|
wget $repo -P /etc/yum.repos.d/; \
|
||||||
|
done
|
||||||
|
echo "---"
|
||||||
|
fi
|
||||||
|
|
||||||
# Run scripts.
|
# Run scripts.
|
||||||
echo "-- Running scripts defined in recipe.yml --"
|
echo "-- Running scripts defined in recipe.yml --"
|
||||||
buildscripts=$(yq '.scripts[]' < /usr/etc/ublue-recipe.yml)
|
buildscripts=$(yq '.scripts[]' < /usr/etc/ublue-recipe.yml)
|
||||||
@@ -15,15 +25,7 @@ echo "---"
|
|||||||
# Remove the default firefox (from fedora) in favor of the flatpak.
|
# Remove the default firefox (from fedora) in favor of the flatpak.
|
||||||
rpm-ostree override remove firefox firefox-langpacks
|
rpm-ostree override remove firefox firefox-langpacks
|
||||||
|
|
||||||
repos=$(yq '.extrarepos[]' < /usr/etc/ublue-recipe.yml)
|
# Install RPMs.
|
||||||
if [[ -n "$repos" ]]; then
|
|
||||||
echo "-- Adding repos defined in recipe.yml --"
|
|
||||||
for repo in $(echo -e "$repos"); do \
|
|
||||||
wget $repo -P /etc/yum.repos.d/; \
|
|
||||||
done
|
|
||||||
echo "---"
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "-- Installing RPMs defined in recipe.yml --"
|
echo "-- Installing RPMs defined in recipe.yml --"
|
||||||
rpm_packages=$(yq '.rpms[]' < /usr/etc/ublue-recipe.yml)
|
rpm_packages=$(yq '.rpms[]' < /usr/etc/ublue-recipe.yml)
|
||||||
for pkg in $(echo -e "$rpm_packages"); do \
|
for pkg in $(echo -e "$rpm_packages"); do \
|
||||||
|
|||||||
Reference in New Issue
Block a user