From 9277a13f13a8b5a538de3c7858c46a5d1484f5b3 Mon Sep 17 00:00:00 2001 From: Kyle Gospodnetich Date: Fri, 26 Jan 2024 14:20:44 -0800 Subject: [PATCH 1/5] feat: Switch to TuneD from PPD --- Containerfile | 14 +++++++++++--- packages.json | 7 +++++++ 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/Containerfile b/Containerfile index 375d8d05a34..1c94d9fbb32 100644 --- a/Containerfile +++ b/Containerfile @@ -61,6 +61,15 @@ RUN sed -i 's@enabled=0@enabled=1@g' /etc/yum.repos.d/_copr_ublue-os-akmods.repo sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/negativo17-fedora-multimedia.repo && \ wget https://copr.fedorainfracloud.org/coprs/che/nerd-fonts/repo/fedora-"${FEDORA_MAJOR_VERSION}"/che-nerd-fonts-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/_copr_che-nerd-fonts-"${FEDORA_MAJOR_VERSION}".repo +# Remove PPD & TLP +RUN rpm-ostree override remove \ + power-profiles-daemon \ + || true && \ + rpm-ostree override remove \ + tlp \ + tlp-rdw \ + || true + # Starship Shell Prompt RUN curl -Lo /tmp/starship.tar.gz "https://github.com/starship/starship/releases/latest/download/starship-x86_64-unknown-linux-gnu.tar.gz" && \ tar -xzf /tmp/starship.tar.gz -C /tmp && \ @@ -81,6 +90,7 @@ RUN wget https://copr.fedorainfracloud.org/coprs/ublue-os/staging/repo/fedora-"$ printf "\n\n[Install]\nWantedBy=bluefin-cli.target" >> /usr/etc/containers/systemd/users/bluefin-cli.container && \ sed -i '/AutoUpdate.*/ s/^#*/#/' /usr/etc/containers/systemd/users/bluefin-cli.container && \ sed -i 's/ContainerName=bluefin/ContainerName=bluefin-cli/' /usr/etc/containers/systemd/users/bluefin-cli.container && \ + systemctl enable tuned.service && \ systemctl enable rpm-ostree-countme.service && \ systemctl enable tailscaled.service && \ systemctl enable dconf-update.service && \ @@ -100,6 +110,7 @@ RUN wget https://copr.fedorainfracloud.org/coprs/ublue-os/staging/repo/fedora-"$ echo "Hidden=true" >> /usr/share/applications/nvtop.desktop && \ echo "Hidden=true" >> /usr/share/applications/gnome-system-monitor.desktop && \ rm -f /etc/yum.repos.d/_copr_che-nerd-fonts-"${FEDORA_MAJOR_VERSION}".repo && \ + sed -i 's@Name=tuned-gui@Name=TuneD Manager@g' /usr/share/applications/tuned-gui.desktop && \ sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/user.conf && \ sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/system.conf && \ sed -i '/^PRETTY_NAME/s/Silverblue/Bluefin/' /usr/lib/os-release && \ @@ -138,9 +149,6 @@ RUN wget https://copr.fedorainfracloud.org/coprs/ganto/lxc4/repo/fedora-"${FEDOR RUN /tmp/build.sh && \ /tmp/image-info.sh -## power-profiles-daemon with amd p-state support, remove when this is upstream -RUN rpm-ostree override replace --experimental --from repo=copr:copr.fedorainfracloud.org:ublue-os:staging power-profiles-daemon - RUN wget https://github.com/docker/compose/releases/latest/download/docker-compose-linux-x86_64 -O /tmp/docker-compose && \ install -c -m 0755 /tmp/docker-compose /usr/bin diff --git a/packages.json b/packages.json index d29dc38d250..de0fb7f3ffa 100644 --- a/packages.json +++ b/packages.json @@ -38,6 +38,13 @@ "stress-ng", "tailscale", "tmux", + "tuned", + "tuned-ppd", + "tuned-utils", + "tuned-utils-systemtap", + "tuned-gtk", + "tuned-profiles-atomic", + "tuned-profiles-cpu-partitioning", "usbmuxd", "wireguard-tools", "xprop", From 9f7d0e63c2f2ba7d82bbf5d4f71cf8fa96f4c992 Mon Sep 17 00:00:00 2001 From: Kyle Gospodnetich Date: Sat, 27 Jan 2024 11:00:37 -0800 Subject: [PATCH 2/5] chore: Drop TuneD-GUI --- Containerfile | 1 - packages.json | 2 -- 2 files changed, 3 deletions(-) diff --git a/Containerfile b/Containerfile index 1c94d9fbb32..60156d8bfc7 100644 --- a/Containerfile +++ b/Containerfile @@ -110,7 +110,6 @@ RUN wget https://copr.fedorainfracloud.org/coprs/ublue-os/staging/repo/fedora-"$ echo "Hidden=true" >> /usr/share/applications/nvtop.desktop && \ echo "Hidden=true" >> /usr/share/applications/gnome-system-monitor.desktop && \ rm -f /etc/yum.repos.d/_copr_che-nerd-fonts-"${FEDORA_MAJOR_VERSION}".repo && \ - sed -i 's@Name=tuned-gui@Name=TuneD Manager@g' /usr/share/applications/tuned-gui.desktop && \ sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/user.conf && \ sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/system.conf && \ sed -i '/^PRETTY_NAME/s/Silverblue/Bluefin/' /usr/lib/os-release && \ diff --git a/packages.json b/packages.json index de0fb7f3ffa..060fe551a7a 100644 --- a/packages.json +++ b/packages.json @@ -42,9 +42,7 @@ "tuned-ppd", "tuned-utils", "tuned-utils-systemtap", - "tuned-gtk", "tuned-profiles-atomic", - "tuned-profiles-cpu-partitioning", "usbmuxd", "wireguard-tools", "xprop", From c65f7dc373cbc953a4219697455155508bb846fc Mon Sep 17 00:00:00 2001 From: Kyle Gospodnetich Date: Mon, 29 Jan 2024 13:25:19 -0800 Subject: [PATCH 3/5] chore: Install TuneD on F39 only --- Containerfile | 22 +++++++++++----------- packages.json | 12 ++++++------ 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/Containerfile b/Containerfile index 60156d8bfc7..84d4f41ec51 100644 --- a/Containerfile +++ b/Containerfile @@ -30,7 +30,14 @@ RUN if [ ${FEDORA_MAJOR_VERSION} -ge "39" ]; then \ vte-profile && \ rpm-ostree install \ prompt && \ - rm -f /etc/yum.repos.d/_copr_kylegospo-prompt.repo \ + rm -f /etc/yum.repos.d/_copr_kylegospo-prompt.repo && \ + rpm-ostree override remove \ + power-profiles-daemon \ + || true && \ + rpm-ostree override remove \ + tlp \ + tlp-rdw \ + || true \ ; fi COPY usr /usr @@ -61,15 +68,6 @@ RUN sed -i 's@enabled=0@enabled=1@g' /etc/yum.repos.d/_copr_ublue-os-akmods.repo sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/negativo17-fedora-multimedia.repo && \ wget https://copr.fedorainfracloud.org/coprs/che/nerd-fonts/repo/fedora-"${FEDORA_MAJOR_VERSION}"/che-nerd-fonts-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/_copr_che-nerd-fonts-"${FEDORA_MAJOR_VERSION}".repo -# Remove PPD & TLP -RUN rpm-ostree override remove \ - power-profiles-daemon \ - || true && \ - rpm-ostree override remove \ - tlp \ - tlp-rdw \ - || true - # Starship Shell Prompt RUN curl -Lo /tmp/starship.tar.gz "https://github.com/starship/starship/releases/latest/download/starship-x86_64-unknown-linux-gnu.tar.gz" && \ tar -xzf /tmp/starship.tar.gz -C /tmp && \ @@ -90,7 +88,9 @@ RUN wget https://copr.fedorainfracloud.org/coprs/ublue-os/staging/repo/fedora-"$ printf "\n\n[Install]\nWantedBy=bluefin-cli.target" >> /usr/etc/containers/systemd/users/bluefin-cli.container && \ sed -i '/AutoUpdate.*/ s/^#*/#/' /usr/etc/containers/systemd/users/bluefin-cli.container && \ sed -i 's/ContainerName=bluefin/ContainerName=bluefin-cli/' /usr/etc/containers/systemd/users/bluefin-cli.container && \ - systemctl enable tuned.service && \ + if [[ "${FEDORA_MAJOR_VERSION}" -ge "39" ]]; then \ + systemctl enable tuned.service \ + ; fi && \ systemctl enable rpm-ostree-countme.service && \ systemctl enable tailscaled.service && \ systemctl enable dconf-update.service && \ diff --git a/packages.json b/packages.json index 060fe551a7a..33ad456b1d9 100644 --- a/packages.json +++ b/packages.json @@ -38,11 +38,6 @@ "stress-ng", "tailscale", "tmux", - "tuned", - "tuned-ppd", - "tuned-utils", - "tuned-utils-systemtap", - "tuned-profiles-atomic", "usbmuxd", "wireguard-tools", "xprop", @@ -137,7 +132,12 @@ "bluefin": [ "gnome-shell-extension-tailscale-gnome-qs", "input-leap", - "nautilus-open-any-terminal" + "nautilus-open-any-terminal", + "tuned", + "tuned-ppd", + "tuned-utils", + "tuned-utils-systemtap", + "tuned-profiles-atomic", ], "bluefin-dx": [], "bluefin-framework": [] From 646fc261d738eca604e1cdd84882769406f5526b Mon Sep 17 00:00:00 2001 From: Kyle Gospodnetich Date: Mon, 29 Jan 2024 13:30:57 -0800 Subject: [PATCH 4/5] chore: Fix spaces used instead of tabs --- packages.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages.json b/packages.json index 33ad456b1d9..1e804709ccf 100644 --- a/packages.json +++ b/packages.json @@ -132,7 +132,7 @@ "bluefin": [ "gnome-shell-extension-tailscale-gnome-qs", "input-leap", - "nautilus-open-any-terminal", + "nautilus-open-any-terminal", "tuned", "tuned-ppd", "tuned-utils", From e075ba24eb413f7e12ca7d1cdffe094f1abd7f73 Mon Sep 17 00:00:00 2001 From: Kyle Gospodnetich Date: Mon, 29 Jan 2024 13:39:31 -0800 Subject: [PATCH 5/5] chore: Minor syntax fix --- packages.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages.json b/packages.json index 1e804709ccf..21226e2ec5a 100644 --- a/packages.json +++ b/packages.json @@ -137,7 +137,7 @@ "tuned-ppd", "tuned-utils", "tuned-utils-systemtap", - "tuned-profiles-atomic", + "tuned-profiles-atomic" ], "bluefin-dx": [], "bluefin-framework": []