2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-13 10:35:40 +00:00

Use gpg for install script instead of apt-key (#5856)

* possible fix to #5838

* fixed syntax
This commit is contained in:
Matthias Mair
2023-11-04 03:11:57 +01:00
committed by GitHub
parent 7396b028d7
commit 19810d0965
2 changed files with 26 additions and 20 deletions

View File

@ -110,10 +110,10 @@ if [[ $NEEDS_LIBSSL1_1 == "true" ]]; then
fi
echo "### Getting and adding key"
wget -qO- https://dl.packager.io/srv/$publisher/InvenTree/key | sudo apt-key add -
curl -fsSL https://dl.packager.io/srv/$publisher/InvenTree/key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/pkgr-inventree.gpg> /dev/null
echo "### Adding package source"
do_call "sudo wget -O /etc/apt/sources.list.d/inventree.list https://dl.packager.io/srv/$publisher/InvenTree/$source_url/installer/$DIST_OS/$DIST_VER.repo"
SOURCE_URL="deb [signed-by=/etc/apt/trusted.gpg.d/pkgr-inventree.gpg] https://dl.packager.io/srv/deb/$publisher/InvenTree/$source_url/$DIST_OS $DIST_VER main"
echo "$SOURCE_URL" | tee /etc/apt/sources.list.d/inventree.list > /dev/null
echo "### Updating package lists"
do_call "sudo apt-get update"