Skip to content

Commit

Permalink
Merge branch 'main' into add-tp_smapi
Browse files Browse the repository at this point in the history
  • Loading branch information
p4p4j0hn authored Dec 17, 2024
2 parents 9c14f90 + fdc8993 commit 53c9976
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 16 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/cleanup.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Cleanup Old Images
on:
schedule:
- cron: "30 0 * * 0" # 0030 UTC on Sundays
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref || github.run_id }}

jobs:
delete-older-than-90:
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- name: Delete Images Older Than 90 Days
uses: dataaxiom/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
packages: akmods,akmods-zfs,akmods-extra,akmods-nvidia-open
older-than: 90 days
delete-orphaned-images: true
keep-n-tagged: 7
keep-n-untagged: 7
4 changes: 2 additions & 2 deletions .github/workflows/reusable-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ jobs:
systemctl status apparmor || true
- name: Pull build images
uses: Wandalen/[email protected].2
uses: Wandalen/[email protected].3
with:
attempt_limit: 3
attempt_delay: 15000
Expand Down Expand Up @@ -266,7 +266,7 @@ jobs:
string: ${{ env.IMAGE_REGISTRY }}

- name: Push To GHCR
uses: Wandalen/[email protected].2
uses: Wandalen/[email protected].3
id: push
if: github.event_name != 'pull_request'
env:
Expand Down
3 changes: 0 additions & 3 deletions build-ublue-os-nvidia-addons.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@ sed -i "s@gpgcheck=0@gpgcheck=1@" /tmp/ublue-os-nvidia-addons/rpmbuild/SOURCES/n
curl -L https://raw.githubusercontent.com/NVIDIA/dgx-selinux/master/bin/RHEL9/nvidia-container.pp \
-o /tmp/ublue-os-nvidia-addons/rpmbuild/SOURCES/nvidia-container.pp

curl -L https://copr.fedorainfracloud.org/coprs/eyecantcu/supergfxctl/repo/fedora-${FEDORA_MAJOR_VERSION}/eyecantcu-supergfxctl-fedora-${FEDORA_MAJOR_VERSION}.repo \
-o /tmp/ublue-os-nvidia-addons/rpmbuild/SOURCES/eyecantcu-supergfxctl.repo


rpmbuild -ba \
--define '_topdir /tmp/ublue-os-nvidia-addons/rpmbuild' \
Expand Down
3 changes: 0 additions & 3 deletions test-prep.sh
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ if [[ -f $(find /tmp/akmods-rpms/kmods/kmod-nvidia-*.rpm) ]]; then
"https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo"
curl -Lo /etc/yum.repos.d/nvidia-container.pp \
"https://raw.githubusercontent.com/NVIDIA/dgx-selinux/master/bin/RHEL9/nvidia-container.pp"
curl -Lo /etc/yum.repos.d/eyecantcu-supergfxctl.repo \
"https://copr.fedorainfracloud.org/coprs/eyecantcu/supergfxctl/repo/fedora-${COPR_RELEASE}/eyecantcu-supergfxctl-fedora-${COPR_RELEASE}.repo"
curl -Lo /tmp/nvidia-install.sh \
"https://raw.githubusercontent.com/ublue-os/hwe/main/nvidia-install.sh"
chmod +x /tmp/nvidia-install.sh
Expand Down Expand Up @@ -125,7 +123,6 @@ fi
rm -f /tmp/certs/private_key_2.priv

if [[ -f $(find /tmp/akmods-rpms/kmods/kmod-nvidia-*.rpm 2> /dev/null) ]]; then
sed -i '0,/enabled=0/{s/enabled=0/enabled=1/}' /etc/yum.repos.d/eyecantcu-supergfxctl.repo
sed -i '0,/enabled=0/{s/enabled=0/enabled=1/}' /etc/yum.repos.d/negativo17-fedora-nvidia.repo
sed -i '0,/enabled=0/{s/enabled=0/enabled=1/}' /etc/yum.repos.d/nvidia-container-toolkit.repo
source /tmp/akmods-rpms/kmods/nvidia-vars
Expand Down
13 changes: 5 additions & 8 deletions ublue-os-nvidia-addons.spec
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Name: ublue-os-nvidia-addons
Version: 0.10
Version: 0.12
Release: 1%{?dist}
Summary: Additional files for nvidia driver support

Expand All @@ -15,8 +15,7 @@ Source2: ublue-nvctk-cdi.service
Source3: 70-ublue-nvctk-cdi.preset
Source4: environment
Source5: negativo17-fedora-nvidia.repo
Source6: eyecantcu-supergfxctl.repo
Source7: 60-nvidia-extra-devices-pm.rules
Source6: 60-nvidia-extra-devices-pm.rules

%description
Adds various runtime files for nvidia support.
Expand All @@ -32,33 +31,31 @@ install -Dm0644 %{SOURCE2} %{buildroot}%{_datadir}/ublue-os/%{_unitdir}/ublue-nv
install -Dm0644 %{SOURCE3} %{buildroot}%{_presetdir}/70-ublue-nvctk-cdi.preset
install -Dm0644 %{SOURCE4} %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/sway/environment
install -Dm0644 %{SOURCE5} %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/negativo17-fedora-nvidia.repo
install -Dm0644 %{SOURCE6} %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/eyecantcu-supergfxctl.repo

sed -i 's@enabled=1@enabled=0@g' %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/eyecantcu-supergfxctl.repo
sed -i 's@enabled=1@enabled=0@g' %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/negativo17-fedora-nvidia.repo
sed -i 's@enabled=1@enabled=0@g' %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/nvidia-container-toolkit.repo

install -Dm0644 %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/negativo17-fedora-nvidia.repo %{buildroot}%{_sysconfdir}/yum.repos.d/negativo17-fedora-nvidia.repo
install -Dm0644 %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/eyecantcu-supergfxctl.repo %{buildroot}%{_sysconfdir}/yum.repos.d/eyecantcu-supergfxctl.repo
install -Dm0644 %{buildroot}%{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/nvidia-container-toolkit.repo %{buildroot}%{_sysconfdir}/yum.repos.d/nvidia-container-toolkit.repo
install -Dm0644 %{buildroot}%{_datadir}/ublue-os/%{_datadir}/selinux/packages/nvidia-container.pp %{buildroot}%{_datadir}/selinux/packages/nvidia-container.pp
install -Dm0644 %{buildroot}%{_datadir}/ublue-os/%{_unitdir}/ublue-nvctk-cdi.service %{buildroot}%{_unitdir}/ublue-nvctk-cdi.service

%files
%attr(0644,root,root) %{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/negativo17-fedora-nvidia.repo
%attr(0644,root,root) %{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/nvidia-container-toolkit.repo
%attr(0644,root,root) %{_datadir}/ublue-os/%{_sysconfdir}/yum.repos.d/eyecantcu-supergfxctl.repo
%attr(0644,root,root) %{_datadir}/ublue-os/%{_datadir}/selinux/packages/nvidia-container.pp
%attr(0644,root,root) %{_datadir}/ublue-os/%{_sysconfdir}/sway/environment
%attr(0644,root,root) %{_datadir}/ublue-os/%{_unitdir}/ublue-nvctk-cdi.service
%attr(0644,root,root) %{_sysconfdir}/yum.repos.d/negativo17-fedora-nvidia.repo
%attr(0644,root,root) %{_sysconfdir}/yum.repos.d/nvidia-container-toolkit.repo
%attr(0644,root,root) %{_sysconfdir}/yum.repos.d/eyecantcu-supergfxctl.repo
%attr(0644,root,root) %{_datadir}/selinux/packages/nvidia-container.pp
%attr(0644,root,root) %{_unitdir}/ublue-nvctk-cdi.service
%attr(0644,root,root) %{_presetdir}/70-ublue-nvctk-cdi.preset

%changelog
* Sun Nov 24 2024 RJ Trujillo <[email protected]> - 0.12
- Remove supergfxctl copr as it has been relocated to staging

* Sat Apr 13 Benjamin Sherman <[email protected]> - 0.11
- Add negativo17 fedora-nvidia repo for switch of NVIDIA driver source
- Provided third-party repos are no longer enabled by default
Expand Down

0 comments on commit 53c9976

Please sign in to comment.