Skip to content

chore: refactor package installation and handling during build time - #1142

Merged
inffy merged 52 commits into
ublue-os:mainfrom
inffy:package-json-remove
Oct 25, 2025
Merged

chore: refactor package installation and handling during build time#1142
inffy merged 52 commits into
ublue-os:mainfrom
inffy:package-json-remove

Conversation

@inffy

@inffy inffy commented Oct 23, 2025

Copy link
Copy Markdown
Member

Refactor the package installation and COPR stuff

Closes #1115

@inffy inffy changed the title feat: package.json removal start feat: package.json removal Oct 23, 2025
@inffy

inffy commented Oct 23, 2025

Copy link
Copy Markdown
Member Author

Well it builds now. Now just have to figure out if we are missing something important

@renner0e

renner0e commented Oct 24, 2025

Copy link
Copy Markdown
Member

git-subtree

we never added any of them did we? This is just bluefin legacy I guess?

we don't even have those installed for whatever reason, on brew

➜  podman run -it ghcr.io/ublue-os/aurora-dx:stable-daily bash
bash-5.2# rpm -qi git-subtree
package git-subtree is not installed
bash-5.2# rpm -qi git-subtree
package git-subtree is not installed
bash-5.2# dnf search git-subtree
git-subtree.noarch     Git tools to merge and split repositories
bash-5.2# dnf5 install git-subtree
Updating and loading repositories:
Repositories loaded.
Package                        Arch      Version                         Repository            Size
Installing:
git-subtree                   noarch    2.51.0-2.fc42                   updates           93.0 KiB

same for git-svn, it's on brew anyway

bash-5.2# rpm -qi git-svn
package git-svn is not installed
bash-5.2# rpm -qi git-svn^C
bash-5.2# git svn
git: 'svn' is not a git command. See 'git --help'.

The most similar commands are
fsck
mv
show
bash-5.2# dnf install git-svn
Updating and loading repositories:
Repositories loaded.
Package                        Arch      Version                         Repository            Size
Installing:
git-svn                       noarch    2.51.0-2.fc42                   updates          212.0 KiB

the reason for adding git-svn was too much dependencies needed on brew
ublue-os/bluefin#2804

@inffy
inffy marked this pull request as ready for review October 24, 2025 15:29
Copilot AI review requested due to automatic review settings October 24, 2025 15:29
@inffy
inffy requested a review from ledif as a code owner October 24, 2025 15:29

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refactors the package installation process to use isolated COPR repository enablement, improving security by preventing malicious repositories from injecting fake versions of Fedora packages. The changes remove the global enabling of COPR repositories and introduce helper functions for secure, isolated package installation.

Key changes:

  • Introduces isolated COPR installation pattern where repositories are enabled only for specific package installs
  • Removes packages.json configuration file in favor of explicit package lists in build scripts
  • Adds repository validation script to ensure all repos are disabled before image commit

Reviewed Changes

Copilot reviewed 18 out of 18 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
packages.json Removed entire JSON configuration file containing package lists
build_files/shared/copr-helpers.sh New helper functions for isolated COPR and third-party repo installation
build_files/shared/validate-repos.sh New validation script to ensure all repositories are disabled before commit
build_files/base/04-packages.sh Refactored to use explicit package arrays and isolated COPR installation
build_files/dx/03-packages-dx.sh Refactored DX packages to use isolated COPR installation pattern
build_files/base/02-install-copr-repos.sh Removed file that globally enabled COPR repositories
build_files/dx/01-install-copr-repos-dx.sh Removed file that globally enabled COPR repositories for DX
build_files/dx/02-install-kernel-akmods-dx.sh Removed DX-specific kernel/akmod installation script
build_files/base/17-cleanup.sh Updated cleanup to handle isolated repo pattern
build_files/dx/09-cleanup-dx.sh Simplified cleanup for isolated repo pattern
build_files/shared/build-base.sh Removed packages.json copy and COPR repos script call, added validation
build_files/shared/build-dx.sh Removed packages.json copy and COPR/akmods script calls, added validation
build_files/base/05-override-install.sh Moved Starship installation to use direct binary download
build_files/base/03-install-kernel-akmods.sh Restructured conditional logic for beta/stable AKMOD installation
build_files/base/20-tests.sh Removed starship from test packages list
build_files/dx/10-tests-dx.sh Removed lxc from DX test packages and trailing newline
just/aurora-system.just Removed configure-vfio recipe (104 lines)
Containerfile Removed packages.json from COPY instructions

Comment thread build_files/shared/validate-repos.sh
Comment thread build_files/shared/copr-helpers.sh
Comment thread build_files/dx/03-packages-dx.sh
Comment thread build_files/base/04-packages.sh Outdated
Comment thread build_files/base/04-packages.sh
Comment thread build_files/base/03-install-kernel-akmods.sh
Comment thread build_files/dx/09-cleanup-dx.sh Outdated
inffy and others added 4 commits October 24, 2025 18:35
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@inffy
inffy requested a review from Copilot October 24, 2025 16:22

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 18 out of 18 changed files in this pull request and generated 3 comments.

Comment thread build_files/shared/copr-helpers.sh
Comment thread build_files/dx/03-packages-dx.sh
Comment thread build_files/base/04-packages.sh
@inffy
inffy enabled auto-merge October 24, 2025 16:30
@inffy

inffy commented Oct 24, 2025

Copy link
Copy Markdown
Member Author

Think we are ready (finally)

@renner0e

renner0e commented Oct 24, 2025

Copy link
Copy Markdown
Member
image I think we are missing our dnf swap for fwupd

last blocker ublue-os/packages#978

@renner0e renner0e left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LESS GOOO

@inffy
inffy added this pull request to the merge queue Oct 24, 2025
Merged via the queue into ublue-os:main with commit 932d2b3 Oct 25, 2025
22 checks passed
@inffy
inffy deleted the package-json-remove branch October 25, 2025 00:30
renner0e added a commit to renner0e/aurora that referenced this pull request Nov 1, 2025
renner0e added a commit to renner0e/aurora that referenced this pull request Nov 1, 2025
github-merge-queue Bot pushed a commit that referenced this pull request Nov 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

get rid of packages.json

3 participants