Skip to content

Commit 07fd2d1

Browse files
committed
trixie: apt: Fix yunohost repository installation
1 parent efc9257 commit 07fd2d1

1 file changed

Lines changed: 16 additions & 11 deletions

File tree

trixie

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -566,28 +566,33 @@ function boring_workarounds() {
566566
echo
567567
}
568568

569+
570+
569571
function setup_package_source() {
570572
echo "" | tee -a "$YUNOHOST_LOG"
571573
echo "" | tee -a "$YUNOHOST_LOG"
572574
echo "$bold 4/5 • Adding YunoHost repository to apt$normal" | tee -a "$YUNOHOST_LOG"
573575
echo "" | tee -a "$YUNOHOST_LOG"
574576

575-
local CUSTOMAPT=/etc/apt/sources.list.d/yunohost.list
576-
577577
# Debian repository
578-
579-
local CUSTOMDEB="deb [signed-by=/usr/share/keyrings/yunohost-trixie.gpg] http://forge.yunohost.org/debian/ trixie stable"
580-
581-
if [[ "$DISTRIB" == "stable" ]] ; then
582-
echo "$CUSTOMDEB" > $CUSTOMAPT
583-
elif [[ "$DISTRIB" == "testing" ]] ; then
584-
echo "$CUSTOMDEB testing" > $CUSTOMAPT
578+
local components="stable"
579+
if [[ "$DISTRIB" == "testing" ]] ; then
580+
components="$components testing"
585581
elif [[ "$DISTRIB" == "unstable" ]] ; then
586-
echo "$CUSTOMDEB testing unstable" > $CUSTOMAPT
582+
components="$components testing unstable"
587583
fi
588584

585+
local deb_sources="
586+
Types: deb
587+
URIs: http://repo.yunohost.org/debian/
588+
Suites: trixie
589+
Components: $components
590+
Signed-By: /etc/apt/trusted.gpg.d/yunohost-trixie.gpg
591+
"
592+
echo "$deb_sources" > /etc/apt/sources.list.d/yunohost.sources
593+
589594
# Add YunoHost repository key to the keyring
590-
curl --fail --silent https://forge.yunohost.org/yunohost_trixie.asc | gpg --dearmor > /usr/share/keyrings/yunohost-trixie.gpg
595+
curl --fail --silent https://repo.yunohost.org/keys/yunohost_trixie.asc | gpg --dearmor > /etc/apt/trusted.gpg.d/yunohost-trixie.gpg
591596
apt_update
592597
}
593598

0 commit comments

Comments
 (0)