From b07706fd7a6b77e8643425b5932830d163c9bf50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Fri, 12 Jan 2018 04:54:07 +0100 Subject: [PATCH] dom0-updates: launch console update in terminal emulator as "GUI" GUI updaters and Packagekit are confused by networkless dom0 and often report that: - cannot check for updates (because of no network connection) - no updates are available, even if they are The latter happen mostly because PackageKit does not load dnf.conf, so try to use /etc/yum.repos.d (network repositories) instead of /etc/yum.real.repos.d (local cache, downloaded by qubes-dom0-update). Currently PackageKit does not support configuring it, the path is hardcoded. Until both of above issues get fixed, prefer console updater. Fixes QubesOS/qubes-issues#1378 --- dom0-updates/qubes-dom0-update | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dom0-updates/qubes-dom0-update b/dom0-updates/qubes-dom0-update index 486b08d..93b7548 100755 --- a/dom0-updates/qubes-dom0-update +++ b/dom0-updates/qubes-dom0-update @@ -113,10 +113,10 @@ if [ "$GUI" == "1" -a -n "$PKGS" ]; then fi if [ "$GUI" == "1" ]; then - apps="yumex apper gpk-update-viewer" + apps="xterm konsole yumex apper gpk-update-viewer" if [ -n "$KDE_FULL_SESSION" ]; then - apps="apper yumex gpk-update-viewer" + apps="konsole xterm apper yumex gpk-update-viewer" fi guiapp= @@ -125,6 +125,8 @@ if [ "$GUI" == "1" ]; then guiapp=$app case $guiapp in apper) guiapp="apper --updates --nofork" ;; + xterm) guiapp="xterm -e sudo dnf update" ;; + konsole) guiapp="konsole --hold -e sudo dnf update" ;; *) guiapp=$app ;; esac break;