Skip to content

Commit

Permalink
bootc: Set 'installonlypkgs=' in /etc/dnf/dnf.conf
Browse files Browse the repository at this point in the history
On bootc installs, disable the installonlypkgs list so we do not end
up with multiple kernels.

Fixes: SWM-3028

Signed-off-by: David Cantrell <[email protected]>
  • Loading branch information
dcantrell committed Dec 16, 2024
1 parent 0e71e95 commit 4f9fc3e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions dnf.spec
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ Conflicts: python3-dnf-plugins-extras-common < %{conflicts_dnf_plugins_extr

%package data
Summary: Common data and configuration files for DNF
Requires(post): /usr/bin/sed
%if %{with dnf5_obsoletes_dnf}
Requires: /etc/dnf/dnf.conf
%endif
Expand Down Expand Up @@ -309,6 +310,12 @@ popd
%endif


%post data
if [ -f "/run/ostree-booted" ] && [ ! -w "/usr/" ]; then
sed -i -e '/^[main]/a installonlypkgs=' %{confdir}/%{name}.conf
fi


%if %{without dnf5_obsoletes_dnf}
%files -f %{name}.lang
%{_bindir}/%{name}
Expand Down

0 comments on commit 4f9fc3e

Please sign in to comment.