diff --git a/Containerfile b/Containerfile index 404f1d258e6..d00df791270 100644 --- a/Containerfile +++ b/Containerfile @@ -100,9 +100,8 @@ RUN wget https://copr.fedorainfracloud.org/coprs/ublue-os/staging/repo/fedora-"$ systemctl enable dconf-update.service && \ systemctl enable ublue-update.timer && \ systemctl enable ublue-system-setup.service && \ - systemctl enable ublue-system-networked-tasks.service && \ - systemctl enable brew-install-workaround.service && \ - systemctl --global enable ublue-user-networked-tasks.service && \ + systemctl enable ublue-system-flatpak-manager.service && \ + systemctl --global enable ublue-user-flatpak-manager.service && \ systemctl --global enable ublue-user-setup.service && \ fc-cache -f /usr/share/fonts/ubuntu && \ fc-cache -f /usr/share/fonts/inter && \ diff --git a/usr/lib/systemd/system/brew-install-workaround.service b/usr/lib/systemd/system/brew-install-workaround.service deleted file mode 100644 index 4d39b1465b3..00000000000 --- a/usr/lib/systemd/system/brew-install-workaround.service +++ /dev/null @@ -1,20 +0,0 @@ -[Unit] -Description=Workaround brew-install not having the correct caps -ConditionFileIsExecutable=/usr/libexec/brew-install -After=local-fs.target - -[Service] -Type=oneshot -# Copy if it doesn't exist -ExecStartPre=/usr/bin/bash -c "[ -x /usr/local/libexec/.brew-install ] || /usr/bin/cp /usr/libexec/brew-install /usr/local/libexec/.brew-install" -# This is faster than using .mount unit. Also allows for the previous line/cleanup -ExecStartPre=/usr/bin/mount --bind /usr/local/libexec/.brew-install /usr/libexec/brew-install -# Fix caps -ExecStart=/usr/sbin/setcap 'cap_sys_admin+p' /usr/libexec/brew-install -# Clean-up after ourselves -ExecStop=/usr/bin/umount /usr/libexec/brew-install -ExecStop=/usr/bin/rm /usr/local/libexec/.brew-install -RemainAfterExit=yes - -[Install] -WantedBy=multi-user.target diff --git a/usr/lib/systemd/system/ublue-system-networked-tasks.service b/usr/lib/systemd/system/ublue-system-flatpak-manager.service similarity index 70% rename from usr/lib/systemd/system/ublue-system-networked-tasks.service rename to usr/lib/systemd/system/ublue-system-flatpak-manager.service index 5e5d6db8341..85631cbbe7e 100644 --- a/usr/lib/systemd/system/ublue-system-networked-tasks.service +++ b/usr/lib/systemd/system/ublue-system-flatpak-manager.service @@ -1,12 +1,12 @@ [Unit] -Description=Manage tasks that require network access (Flatpaks) +Description=Manage system flatpaks Documentation=https://github.com/ublue-os/endlish-oesque/issues/10 Wants=network-online.target After=network-online.target ublue-system-setup.service [Service] Type=oneshot -ExecStart=/usr/libexec/ublue-system-networked-tasks +ExecStart=/usr/libexec/ublue-system-flatpak-manager Restart=on-failure RestartSec=30 StartLimitInterval=0 diff --git a/usr/lib/systemd/user/ublue-user-networked-tasks.service b/usr/lib/systemd/user/ublue-user-flatpak-manager.service similarity index 65% rename from usr/lib/systemd/user/ublue-user-networked-tasks.service rename to usr/lib/systemd/user/ublue-user-flatpak-manager.service index 00e98bfebeb..037fb2eea78 100644 --- a/usr/lib/systemd/user/ublue-user-networked-tasks.service +++ b/usr/lib/systemd/user/ublue-user-flatpak-manager.service @@ -1,12 +1,12 @@ [Unit] -Description=Manage user activities that require network access (Flatpaks, Brew) +Description=Manage user flatpaks Documentation=https://github.com/ublue-os/endlish-oesque/issues/10 Wants=network-online.target After=network-online.target [Service] Type=oneshot -ExecStart=/usr/libexec/ublue-user-networked-tasks +ExecStart=/usr/libexec/ublue-user-flatpak-manager Restart=on-failure RestartSec=30 StartLimitInterval=0 diff --git a/usr/lib/tmpfiles.d/brew-install-workaround.conf b/usr/lib/tmpfiles.d/brew-install-workaround.conf deleted file mode 100644 index e997f53d386..00000000000 --- a/usr/lib/tmpfiles.d/brew-install-workaround.conf +++ /dev/null @@ -1 +0,0 @@ -C /usr/local/libexec/.brew-install - - - - /usr/libexec/brew-install diff --git a/usr/libexec/configure-terminal.sh b/usr/libexec/configure-terminal.sh index 8f3fc3cb351..a96433affa4 100755 --- a/usr/libexec/configure-terminal.sh +++ b/usr/libexec/configure-terminal.sh @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/usr/bin/bash # shellcheck source=/dev/null source /usr/lib/ujust/ujust.sh diff --git a/usr/libexec/ublue-system-networked-tasks b/usr/libexec/ublue-system-flatpak-manager similarity index 89% rename from usr/libexec/ublue-system-networked-tasks rename to usr/libexec/ublue-system-flatpak-manager index e9cf03dca5b..d7659c743a9 100755 --- a/usr/libexec/ublue-system-networked-tasks +++ b/usr/libexec/ublue-system-flatpak-manager @@ -1,13 +1,13 @@ -#!/usr/bin/env bash +#!/usr/bin/bash # Script Version VER=3 -VER_FILE="/etc/ublue/networked_tasks_version" +VER_FILE="/etc/ublue/flatpak_manager_version" VER_RAN=$(cat $VER_FILE) # Run script if updated if [[ -f $VER_FILE && $VER = $VER_RAN ]]; then - echo "Networked tasks v$VER has already ran. Exiting..." + echo "Flatpak manager v$VER has already ran. Exiting..." exit 0 fi diff --git a/usr/libexec/ublue-system-setup b/usr/libexec/ublue-system-setup index c807ed6a839..4e97b7ba18f 100755 --- a/usr/libexec/ublue-system-setup +++ b/usr/libexec/ublue-system-setup @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/usr/bin/bash IMAGE_INFO="/usr/share/ublue-os/image-info.json" IMAGE_NAME=$(jq -r '."image-name"' < $IMAGE_INFO) diff --git a/usr/libexec/ublue-user-networked-tasks b/usr/libexec/ublue-user-flatpak-manager similarity index 77% rename from usr/libexec/ublue-user-networked-tasks rename to usr/libexec/ublue-user-flatpak-manager index 6ecbc221700..adc8ad22474 100755 --- a/usr/libexec/ublue-user-networked-tasks +++ b/usr/libexec/ublue-user-flatpak-manager @@ -1,8 +1,8 @@ -#!/usr/bin/env bash +#!/usr/bin/bash # Script Version VER=5 -VER_FILE="${XDG_DATA_HOME:-$HOME/.local/share}/ublue/networked_tasks_version" +VER_FILE="${XDG_DATA_HOME:-$HOME/.local/share}/ublue/flatpak_manager_version" VER_RAN=$(cat $VER_FILE) mkdir -p "$(dirname "$VER_FILE")" || exit 1 @@ -50,11 +50,4 @@ fi notify-send "Flatpak installer" "Finished installing user flatpaks" --app-name="Flatpak installer" -u NORMAL -# Install brew -if [[ ! -f "/var/home/linuxbrew/.linuxbrew/bin" || ! -x "/var/home/linuxbrew/.linuxbrew/bin/brew" ]]; then - /usr/bin/bash -c 'env NONINTERACTIVE=1 /usr/libexec/brew-install' -fi - -notify-send "Brew installer" "Finished installing brew package manager" --app-name="Brew installer" -u NORMAL - echo $VER > $VER_FILE diff --git a/usr/libexec/ublue-user-setup b/usr/libexec/ublue-user-setup index b6ec3a28624..d4f5c8e4faf 100755 --- a/usr/libexec/ublue-user-setup +++ b/usr/libexec/ublue-user-setup @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/usr/bin/bash # SCRIPT VERSION USER_SETUP_VER=5